Quantum Bayesian Networks

September 11, 2018

IBM and Google Caught off Guard by Rigetti Spaghetti

Filed under: Uncategorized — rrtucci @ 5:09 am

Recently, Rigetti, the quantum computer company located in Berkeley, CA, made some bold promises that probably caught IBM and Google off guard, as in the following gif

  • Last month (on Aug 8), Rigetti promised a 128 qubit gate model chip “over the next 12 months”. [comment: Quite ambitious. It may turn out that Rigetti cannot deliver, as promised, a 128 qbit gate model qc in the next 12 months. Nevertheless, Google and IBM must now plan ahead assuming that Rigetti will be on time. IBM and Google may now be forced to speed up their plans for growing the number of qubits in their chips. This is especially true of Google. So far, Google has given a lackluster performance in this race. Their software Cirq is a bad copy of Rigetti’s Pyquil, and much less complete than Pyquil. Also, they promised a 72 qubit chip and cloud service by the beginning of this year but have yet to deliver on that promise. Hurry up Google, you slow-poke!]
  • Then this week (on Sept. 7), Rigetti promised
    1. A “Quantum Cloud Services” (QCS) that intends to compete with Amazon’s cloud services (AWS). Each user of Rigetti’s qc will be given their own virtual environment running Rigetti’s Pyquil and Forest software. [comment: IBM, Google and Microsoft already offer very complete cloud services so they can easily match Rigetti’s cloud offering.]
    2. Partnerships with 12 startups [comment: There is no info in the press release on what generous bounty the startups will get out of this deal. Maybe some Rigetti decals for their laptops, a few Rigetti tee shirts size “small” and some lame bragging rights.]
    3. “$1 million prize for the first conclusive demonstration of quantum advantage on QCS.” [comment: Who knows, the $1M Rigetti prize may spawn similar prizes by IBM and Google. Let’s hope so.]

This is all very good news for our company artiste-qb.net. It raises the value and visibility of the qc field and therefore also of our company. Furthermore, we are hoping that our docker image, Bayesforge, will become an excellent substitute for a Rigetti image. We will be deploying Bayesforge in the next week or two. Stay tuned.


September 3, 2018

Our New, Luxurious, ShenZhen Office, Now Open for Business

Filed under: Uncategorized — rrtucci @ 3:24 am

Eat your heart out Apple, Google, Facebook. We at artiste-qb.net have luxurious corporate offices all over the world, too. Here is our new China (ShenZhen) branch office, headed by our co-founder, Dr. Tao Yin.

Notice corporate logo, in both Chinese and English, on ceiling wall. Open for business. We produce insanely great classical and quantum AI software.

September 2, 2018

IBM Quantum has been “ratted out” by its partners

Filed under: Uncategorized — rrtucci @ 2:04 am

5 months ago (April 7, 2018), IBM Quantum announced to much fanfare that it had selected 8 qc startups to partner with. Well, today I heard from a little bird that IBM CHARGES its esteemed partners


if they want to use its more advanced quantum chips that are not open to the general public. You could buy a sizable fraction of our qc startup artiste-qb.net for that price! And our qc software stack is much better (much better designed and more complete for quantum AI tasks) than IBM’s “designed by committee” quantum software stack. We offer Qubiter (Write Once, Simulate Anywhere), Quantum Fog, Quantum Edward, and BayesForge. LOL, it would be a great honor to be anointed an IBM partner, but we respectfully and regretfully cannot accept the honor. Thanks anyway IBM for the generous offer.

Another widely known secret is that IBM Quantum has refused to participate 2 years in a row, in the quantum Machine Learning incubator class offered yearly by the CDL (Creative Destruction Lab, part of Univ of Toronto). Google and Microsoft have refused too. If you think IBM-Think nurtures qc startups, think again. Google and Microsoft don’t either

I think IBM-Think should try to be more friendly to startups. God knows IBM needs all the friends it can get. It’s well known that IBM stock has been in decline for many years. Warren Buffet used to own a lot of IBM stock but he sold it all; he bought Apple stock instead.

August 21, 2018

Quantum Languages For Babies, for Future Space-Force Cadets

Filed under: Uncategorized — rrtucci @ 5:37 pm

Artiste-qb.net Qubiter (Starship USS Enterprise)

“Space, the final frontier. These are the voyages of the starship Enterprise Qubiter. Its five-year mission: to explore strange new worlds, to seek out new life and new civilizations, to boldly go where no man has gone before.”

Microsoft Q# (Death Star)

IBM Qiskit/qasm (Rusty Tub)

Google Cirq (Donut with sprinkles)

Rigetti PyQuil (Rubber Ducky)

August 18, 2018

Invest in our Canadian Quantum Computing Company as Hedge Against Imminent American Economic Crisis

Filed under: Uncategorized — rrtucci @ 5:32 pm

Our quantum computing software company Artiste-qb.net is based in Toronto and incorporated only in Ontario, Canada. This makes us partly immune to:

  • America’s import restrictions, imposed due to national security concerns, on software, especially those restrictions regulating commerce with China. Our software is all open source, we are an OpenSaaS (open software as a service) company, but those import restrictions plus Trump’s tariff wars, would curtail our business activities if we were based in the US. Actively pursuing the Chinese market is an important part of our business plans. One of our co-founders, Dr. Tao Yin, who lives in ShenZhen China, is spearheading our Chinese activities.

  • what I believe is an inevitable, imminent crisis in the American economy. And I am far from being alone in having such a pessimistic outlook for the near term American economy (for example, check out the following opinion piece entitled “Another Epic Economic Collapse is Coming” by the famous conservative pundit, George Will). Consider the impact on the current American economy of the following driving factors:
    1. A probably ultimately counterproductive tax cut for big business,
    2. tariff wars in which everyone loses, waged against our biggest trade partners China, Mexico, Canada, EU, …,
    3. a steep rise in the national debt,
    4. A renouncing of America’s Land Of Immigrants heritage, which is what, if anything, once made America great,
    5. A population bitterly divided along party lines,
    6. Huge income disparity in population. 1% of Americans now own 70% of the wealth,
    7. a resurgence and acceptance of racial, religious and LGBT prejudice,
    8. A president who on a daily basis Tweets lies, and dumb, banal, embarrassing, racists, misogynist statements. And once he is impeached, we will get Pence, who is another strongly polarizing figure,
    9. removal of regulations that were supposed to protect us from a repeat of financial crisis of 2007–2008
    10. renouncing of any attempts to control or mitigate the very disruptive and costly problem of climate change
    11. disastrous foreign policies
    12. Denigration of the free press, the FBI and our intelligence agencies by Trump and his supporters,
    13. A badly broken Health Care system and no improvement in sight,
    14. A malicious, intransigent and politically super powerful NRA

    This spells “trouble with a capital T” for America.

My advise to you is to invest in our Canadian quantum computing software company artiste-qb.net as a hedge against the looming, imminent American Economic Crisis. Now is the best time to invest in us; the biggest fortunes are made during times of upheaval, not during steady, predictable times.

August 14, 2018

What programming languages are available for quantum computers? What is the best quantum language?

Filed under: Uncategorized — rrtucci @ 1:07 am

Answering this question is Easy Peasy.

Qubiter is the Greatest. It floats like a butterfly and stings like a bee. If Qubiter were a heavy weight fighter, it would be called Muhammad Ali.

Qubiter is insanely great software.

Many supposedly exhaustive lists of quantum languages do NOT list Qubiter; this probably indicates that the list’s authors are DISHONEST people who want to suppress knowledge of the existence of Qubiter because they have an affiliation or conflict of interest with the authors of a competing quantum language. Alas, hype and outright dishonesty in quantum computing is not uncommon in both Academia and Industry. In reality, Qubiter (open source under BSD license) is an excellent alternative to the following popular quantum languages:

  • Google Cirq
  • IBM qasm/qiskit
  • Microsoft Q# (its former version was called Liqui|>)
  • Rigetti PyQuil
  • Project Q
  • Quipper

Caveat Emptor: Here are some features of Qubiter that the other quantum languages may not have:

  • Automatically creates 2 files for the quantum circuit, a Qubiter qasm file and an ASCII picture file. This makes debugging easier (can also draw fancy LaTex picture of circuit but that is slower so only optional) The ascii file and qasm file correspond line by line, so line 5 in each gives 2 representations, ascii and qasm, of the same gate. For example, consider Teleportation. Here is
    Qubiter’s ASCII Picture file for that:


    and here is the corresponding qasm (English) file:



  • Only uses quantum bits instead of quantum and classical registers. Classical registers are an unnecessary and bothersome complication. For example, If you continue developing the classical register operations of PyQuil, you will eventually end up reinventing Python inside PyQuil, which is itself inside Python. That would be the logical conclusion of PyQuil’s classical registers, wouldn’t it?
  • Translates Qubiter qasm to IBM qasm, Google’s Cirq and Rigetti’s PyQuil.
  • Only Qubiter has PRINT statement in its qasm that prints to screen the state vector at the position of the PRINT statement in the qasm
  • Expands arbitrary one qubit gates with any number of controls to a sequence of cnots and single qubit rotations
  • Includes quantum CSD compiler. This compiler can expand an arbitrary n qubit unitary matrix into a sequence of CNOTs and single qubit rotations. The compiler also expands quantum multiplexors and diagonal unitary matrices which are very useful in dealing with Quantum Neural Networks.
  • Is written in Python (Q# is written in Q# and Quipper in Haskell)
  • Gates controlled by classical qubits are handled much more clearly
  • Has nice library of Jupyter notebooks, not as large as IBM qiskit’s, but other languages besides IBM qiskit have almost no Jupyter notebooks
  • 100% object oriented, like JAVA and C++. Other quantum languages written in Python are partly object oriented and partly procedural, which is not as well organized as 100% object oriented.
  • Not made by an international monopoly trying to control the quantum computing field
  • (this is only important to Canadians) Made in Canada, eh. Oh Canada!

August 9, 2018

The world sorely needs alternative to nasty StackOverflow. Build one and you will get rich

Filed under: Uncategorized — rrtucci @ 4:00 pm

I used to be a super-fan of StackOverflow, and would often recommended it to my friends, but nowadays instead I tell them to stay away from StackOverflow’s toxic environment. Read StackOverflow’s answers but boycott the products they advertise.

If you are considering investing in StackOverflow, my advice to you is DON’T. You will lose your money. Do some due-diligence in the Internet and you will find out that StackOverflow is widely disliked for many good reasons.

And if you are an entrepreneur looking to start a new business, I highly recommend building a healthy alternative to StackOverflow; there is a severe need for one.

My opinion about StackOverflow flipped in recent days, when I was subjected to a gang attack by the moderators of Quantum Computing Stack Exchange (a branch of StackOverflow). According to a message they to sent me:

In this specific case, your posts were reviewed by several of the site moderators and a consensus was reached as to how your posts would be moderated.

Sounds like a premeditated gang-rape to me. What kind of company condones such sick behavior?

You can find out the details of my bad experience in my previous blog post. Make no mistake about it, the reasons they give for attacking a coder whose only “crime” is speaking about his own software (software which is open source under the BSD license) are total BS.

I just want to end by saying that I know some coders who suffer from bipolar disorder and I also know some very sensitive teenager coders. I believe these could have been driven easily to suicide by the bullying the moderators of StackOverflow have subject me to. And I’m sure StackOverflow has subjected many other people to similar sick treatment. A gang of thuggish moderators posing as the ultimate authority in coding and physics, insulting you and your work for bogus reasons, encouraging mean people to downvote you, welcome to StackOverflow.

August 8, 2018

I am being bullied and harassed at Quantum Computing Stack Exchange (branch of StackOverflow)

Filed under: Uncategorized — rrtucci @ 1:52 am

Today almost all of my replies at Quantum Computing Stack Exchange (a branch of StackOverflow) were edited or deleted in a very disdainful way, by a bully called Heather. I politely objected to the moderators by email and received the following reply


According to them, I don’t answer the questions and instead use my replies to advertise my products and my website. This is total BS, I always do the utmost to answer the questions in a polite way, and I’ve never mentioned my website. I do give links to some of my jupyter notebooks iff they directly address the issue being asked. Sometimes I also give a link to the Qubiter repo (Qubiter is open source under the BSD license, so it is hardly “a product”), but the Qiskit, pyQuil and Cirq people link to their repo too. If not they should. It’s pretty ridiculous and inconsiderate to the readers to talk about a software program without giving the URL of its github repo.

The bullies also claim that I don’t mention that I’m the author of the software that I link to. Bizarre claim. If I were plagiarizing someone else’s code, that would be a crime. But since when does one have to explicitly state before every line of code that one cites at Quantum Stack Exchange

# I wrote the following line of code all by myself. My mama did not help me.

Other people from IBM, Rigetti and Google frequently answer questions about their software products at Quantum Stack Exchange and are never taken to task for not mentioning their affiliation or conflict of interest. The double standards of these bullies is hilarious in a Sarah Huckabee Sanders, Fox News kind of way.

After receiving the above unacceptable reply from the moderators, I sent the following email to Tim Post, “Director of Community Strategy, Stack Overflow.” Quite frankly, I expect Tim Post will ignore my email, or else will side with the rapists and blame me, the victim, for dressing provocatively. Typical response by authority figures to harassment claims, you know.

​Dear Sir,

I am rrtucci (Robert Tucci) I would like to point out that I am being bullied and harassed at quantum stack overflow. A person called Heather ( a high school student) has just edited ALL my posts in a very disdainful way that implies I am doing something dishonest by explaining my open source software Qubiter. I don’t see why that is dishonest, the IBM, Google and Rigetti people do it all the time and she doesn’t object to that. Who better than the author of a software to explain it? I have worked in quantum computing for more that 15 yrs and have a PhD in physics. I assure you that everything I say in my comments is true.

This is an example of her bullying. My blog post has received a -2 rating and has been edited by her in a disdainful bullying manner whereas the other dishonest posts that omit mentioning my software have received a rating of 26 points

I very much expect that because of this blog post, I will soon be banned from Quantum Stack Exchange and all my posts there will be deleted. Even if they don’t do that, they have succeeded in intimidating me so that I can’t post replies there anymore. Before the above webpage disappears, or is censored, I saved a copy of it. Here it is


The disingenuousness of the replies, other than mine, in that webpage, is obvious and palpable. None of them mentions Qubiter, an excellent, free, open source under BSD license, and very up-to-date alternative. Instead of mentioning Qubiter, they pad the list with dozens of very old, outdated, softwares. Despite their disingenousness, Heather objects only to my reply. Heather doesn’t claim that something that I say in my reply is false, because my reply is 100% true. Instead, she is outraged that I didn’t explicitly state that I wrote Qubiter (she forcibly inserted the sentence “(Disclaimer: I wrote the code for Qubiter.)” implying that I was doing something very dishonest by not mentioning this) but she doesn’t mind that nobody else mentions their affiliations or conflicts of interest. #MeToo

Update: new blog post

August 2, 2018

Konnichiwa (Hello) Nihon (Japan,日本). Quantum Computing MOOC from Keio Univ. in Tokyo

Filed under: Uncategorized — rrtucci @ 8:41 pm

This week, two of our company’s co-founders, Henning Dekant and Tao Yin, were in Tokyo to attend the Quantum Computing Symposium organized by the Canadian Embassy in Tokyo. An important goal of the trip was to promote: our Bayesforge docker image comprising a vast collection of classical and quantum open source softwares, and our softwares combining classical AI and music.

During our stay, we were honored to meet representatives from various Japanese companies and universities interested in Quantum Computing, such as Fujitsu and Keio University.

Keio University, located in central Tokyo, offers an excellent MOOC on quantum computing taught by Profs. Rodney Van Meter and Takahiko Satoh. (By the way, according to Wikipedia, the term MOOC was coined in Canada to refer to one of the first MOOCs ever offered. Hurray, Canada! I am a passionate advocate of MOOCs)

Prof. Van Meter, who was an undergrad at Caltech where he played a mean game of basketball, is much admired by everyone at artiste-qb.net for his unwavering dedication to teaching. Henning, Rodney, and Tao can be seen below.

July 24, 2018

Are You a Young Male Interested in Quantum Computing? We Recommend a Date with ROSA (Write Once, Simulate Anywhere)

Filed under: Uncategorized — rrtucci @ 12:44 am

Five days ago (7/19), Google released it’s much awaited language for quantum computers, called Cirq. Cirq is available at Github as open source under the Apache license. I expect that Google’s 72 qubit quantum computer and accompanying cloud service, also much awaited, will be unveiled soon too.

(Yes, I am referring to the same company that on (7/18), one day before Cirq was released , was fined $5B by the European Union because it favors Google’s search engine in Android devices, and it also is gradually making closed source and proprietary all the new R&D for the key apps in the Android ecosystem, and it also ruthlessly excommunicates anyone who tries to fork the Android repo to produce a serious competitor to Android. It also excommunicates any company that uses any Android fork in any of its products. Google, please say it ain’t so!… and say you won’t try to destroy Qubiter—my qc language and simulator, a microscopic competitor to Cirq.)

Qubiter is available at Github as open source under the BSD license.

So as not to be destroyed by the bad hombres at Google, a mere five days after the release of Cirq, I have given to Qubiter amazing new superpowers. Qubiter now has the ability to translate Qubiter qasm to Google Cirq, IBM qasm and Rigetti Pyquil. I equate these superpowers to the ability to go out on dates with an Italian bombshell actress called ROSA. ROSA is an acronym for

    Write Once, Simulate Anywhere (ROSA)

Let me explain further. In the Qubiter language, you can use as an operation: any one qubit rotation or a swap of two qubits, with any number of controls attached to them. Qubiter has tools (this Jupyter notebook shows how to use those tools) which allow you to expand such multiply controlled operations into simpler “qasm” that contains only single qubit rotations and cnots. If you want to run that Qubiter qasm on IBM’s, Rigetti’s, or Google’s hardware, Qubiter can also translate its qasm to IBM qasm, Rigetti PyQuil and Google Cirq. The notebook below shows how to do this translation


So, the previous notebook in effect shows you how to go on a date with beautiful Miss ROSA. Hurry up and call her before she is all booked up. Signorina ROSA also enjoys befriending other females interested in quantum computing.



July 4, 2018

Why doesn’t the BBVI (Black Box Variational Inference) algorithm use back propagation?

Filed under: Uncategorized — rrtucci @ 1:36 pm

Quantum Edward uses the BBVI training algorithm. Back Propagation, invented by Hinton, seems to be a fundamental part of most ANN (Artificial Neural Networks) training algorithms, where it is used to find gradients used to calculate the increment in the cost function during each iteration. Hence, I was very baffled, even skeptical, upon first encountering the BBVI algorithm, because it does not use back prop. The purpose of this blog post is to shed light on how BBVI can get away with this.

Before I start, let me explain what the terms “hidden (or latent) variable” and “hidden parameter” mean to AI researchers. Hidden variables are the opposite of “observed variables”. In Dustin Tran’s tutorials for Edward, he often represents observed variables by x and hidden variables by z. I will use \theta instead of z, so z=\theta below. The data consists of many samples of the observed variable x. The goal is to find a probability distribution for the hidden variables \theta. A hidden parameter is a special type of hidden variable. In the language of Bayesian networks, a hidden parameter corresponds to a root node (one without any parents) whose node probability distribution is a Kronecker delta function, so, in effect, the node only ever achieves one of its possible states.

Next, we compare algos that use back prop to the BBVI algo, assuming the simplest case of a single hidden parameter \theta (normally, there is more than one hidden parameter). We will assume \theta\in [0, 1]. In quantum neural nets, the hidden parameters are angles by which qubits are rotated. Such angles range over a closed interval, for example, [0, 2\pi]. After normalization of the angles, their ranges can be assumed, without loss of generality, to be [0, 1].

CASE1: Algorithms that use back prop.

Suppose \theta \in [0, 1],\;\;\eta > 0. Consider a cost function C and a model function M such that

C(\theta) = C(M(\theta)).

If we define the change d\theta in \theta by

d\theta = -\eta \frac{dC}{d\theta}= -\eta \frac{dC}{dM} \frac{dM}{d\theta},

then the corresponding change in the cost is

d C = d\theta \frac{dC}{d\theta} = -\eta \left( \frac{dC}{d\theta}\right)^2.

This change in the cost is negative, which is what one wants if one wants to minimize the cost.

CASE2: BBVI algo

Suppose \theta \in [0, 1],\;\;\eta > 0,\;\; \lambda > 0. Consider a reward function R (for BBVI, R = ELBO), a model function M, and a distance function dist(x, y)\geq 0 such that

R(\lambda) = R\left[\sum_\theta dist[M(\theta), P(\theta|\lambda)]\right].

In the last expression, P(\theta|\lambda) is a conditional probability distribution. More specifically, let us assume that P(\theta|\lambda) is the Beta distribution. Check out its Wikipedia article


The Beta distribution depends on two positive parameters \alpha, \beta (that is why it is called the Beta distribution). \alpha, \beta are often called concentrations. Below, we will use the notation

c_1 = \alpha > 0,

c_2 = \beta  > 0,

\lambda = (c_1, c_2).

Using this notation,

P(\theta|\lambda) = {\rm Beta}(\theta; c_1, c_2).

According to the Wikipedia article for the Beta distribution, the mean value of \theta is given in terms of its 2 concentrations by the simple expression

\langle\theta\rangle = \frac{c_1}{c_1 + c_2}.

The variance of \theta is given by a fairly simple expression of c_1 and c_2 too. Look it up in the Wikipedia article for the Beta distribution, if interested.

If we define the change dc_j in the two concentrations by

dc_j = \eta \frac{\partial R}{\partial c_j}

for j=1,2, then the change in the reward function R will be

dR = \sum_{j=1,2} dc_j \frac{\partial R}{\partial c_j}= \eta \sum_{j=1,2} \left(\frac{\partial R}{\partial c_j}\right)^2

This change in the reward is positive, which is what one wants if one wants to maximize the reward.

Comparison of CASE1 and CASE2

In CASE1, we need to calculate the derivative of the model M with respect to the hidden parameter \theta:


In CASE2, we do not need to calculate any derivatives at all of the model M. (That is why it’s called a Black Box algo). We do have to calculate the derivative of P(\theta|\lambda) with respect to c_1 and c_2, but that can be done a priori since P(\theta|\lambda) is known a priori to be the Beta distribution:

\frac{d}{dc_j}\sum_\theta dist[M(\theta), P(\theta|\lambda)]= \sum_\theta \frac{d dist}{dP(\theta|\lambda)} \frac{dP(\theta|\lambda)}{dc_j}

So, in conclusion, in CASE1, we try to find the value of \theta directly. In CASE2, we try to find the parameters c_1 and c_2 which describe the distribution of \theta‘s. For an estimate of \theta, just use \langle \theta \rangle given above.

July 1, 2018

Is Quantum Computing Startup Xanadu, Backed by MIT Prof. Seth Lloyd, Pursuing an Impossible Dream?

Filed under: Uncategorized — rrtucci @ 5:44 pm

As all Python programmers learn soon, if you ever have a question about Python, it’s almost certain that someone has asked that question before at Stack OverFlow, and that someone has provided a good answer to it there. The same company that brings Stack Overflow to us, now brings also “quantum computing stack exchange” (beta started 3 months ago). I’ve answered a few questions there already. Here is the first question I asked:


Quantum Edward, Quantum Computing Software for Medical Diagnosis and GAN (Generative Adversarial Networks)

Filed under: Uncategorized — rrtucci @ 7:28 am

Quantum Edward at this point is just a small library of Python tools for doing classical supervised learning by Quantum Neural Networks (QNNs). The basic idea behind QEdward is pretty simple: In conventional ANN (Artificial Neural Nets), one has layers of activation functions. What if we replace each of those layers by a quantum gate or a sequence of quantum gates and call the whole thing a quantum computer circuit? The replacement quantum gates are selected in a very natural way based on the chain rule of probabilities. We take that idea and run with it.

As the initial author of Quantum Edward, I am often asked to justify its existence by giving some possible use cases. After all, I work for a startup company artiste-qb.net, so the effort spent on Quantum Edward will not be justified in the eyes of our investors if it is a pure academic exercise with no real-world uses. So let me propose two potential uses.

(1) Medical Diagnosis

It is interesting that the Bayesian Variational Inference method that Quantum Edward currently uses was first used in 1999 by Michael Jordan (Berkeley Univ. prof with same name as the famous basketball player) to do medical diagnosis using Bayesian Networks. So the use of B Nets for Medical Diagnosis has been in the plans of b net fans for at least 20 years.


More recently, my friends Johann Marquez (COO of Connexa) and Tao Yin (CTO of artiste-qb.net) have pointed out to me the following very exciting news article:

This AI Just Beat Human Doctors On A Clinical Exam (Forbes, June 28, 2018, by Parmy Olson)

It took 2 years to train the Babylon Health AI, but the investment has begun to pay off. Currently, their AI can diagnose a disease correctly 82% of the time (and that will improve as it continues to learn from each case it considers) while human doctors are correct only 72% of the time on average. Babylon provides an AI chatbot in combination with a remote force of 250 work-from-home human doctors.


The startup’s charismatic founder, Ali Parsa, has called it a world first and a major step towards his ambitious goal of putting accessible healthcare in the hands of everyone on the planet.

Parsa’s most important customer till now has been Britain’s state-run NHS, which since last year has allowed 26,000 citizens in London to switch from its physical GP clinics to Babylon’s service instead. Another 20,000 are on a waiting list to join.

Parsa isn’t shy about his transatlantic ambitions: “I think the U.S. will be our biggest market shortly,” he adds.

Will quantum computers (using quantum AI like Quantum Edward) ever be able to do medical diagnosis more effectively than classical computers? It’s an open question, but I have high hopes that they will.

(2) Generative Adversarial Networks (GAN)

GANs (Wikipedia link) have been much in the news ever since they were invented just 4 years ago, for their ability to make amazingly accurate predictions with very little human aid. For instance, they can generate pictures of human faces that humans have a hard time distinguishing from the real thing, and generate 360 degree views of rooms from only a few single, fixed perspective photos of the room.

Dusting Tran’s Edward (on which Quantum Edward is based) implements inference algorithms of two types, Variational and Monte Carlo. With Edward, one can build classical neural networks that do classification via the so called Black Box Variational Inference (BBVI) algorithm. Can BBVI also be used to do GAN classically? Yes! Check out the following 4 month old paper:

Graphical Generative Adversarial Networks, by Chongxuan Li, Max Welling, Jun Zhu, Bo Zhang https://arxiv.org/abs/1804.03429 (see footnote)

Can this be generalized to quantum mechanics, i.e. can one use BBVI to do classification and GAN on a quantum computer? Probably yes. Quantum Edward already does classification. It should be possible to extend the techniques already in use in Quantum Edward so as to do GAN too. After all, GAN is just 2 neural nets, either classical or quantum, competing against each other.

(footnote) It is interesting to note that 3 out the four authors of this exciting GAN paper work at Tsinghua Univ in Beijing. Their leader is Prof. Jun Zhu (PhD from Tsinghua Univ, post-doc for 4 yrs at Carnegie Mellon), a rising star in the AI and Bayesian Networks community. He is the main architect of the software ZhuSuan. ZhuSuan is available at GitHub under the MIT license. It is a nice alternative to Dustin Tran’s Edward. Like Edward, it implements Bayesian Networks and Hierarchical Models on top of TensorFlow. The above GAN paper and the ZhuSuan software illustrate how advanced China is in AI.

June 24, 2018

Latest Investments in Quantum Computing Startups (May & June 2018)

Filed under: Uncategorized — rrtucci @ 3:38 am

It seems that quantum computing startups have hit a major money artery in the last 2 months. And that’s just the first half of the Summer. The Summer of 2018, with its blisteringly high temperatures of social activity in the US, is going to be one for the books. Movies will be made about it.

  1. QCWare, $6.5M

  2. QxBranch, $8.5M

  3. Yale qc, $16M in 4 yrs from ARO (Army Research Office, a political organization, like all US federal agencies)

  4. Strangeworks, $4M

  5. Zapata, $5.4M

  6. Xanadu, $9M

  7. gtn.ai, $3M

June 15, 2018

Quantum Edward, models with complex-valued layers

Filed under: Uncategorized — rrtucci @ 4:31 am

The Quantum Edward Python lib (its github repo here), in its first version, comes with 2 models called NbTrolsModel and NoNbTrolsModel. However, the lib is written with enough generality so that you can also run it with other models of your own devising. A model describes a quantum circuit for a QNN (Quantum Neural Network) which is split into layers.

Below is an excerpt from the docstring for the QEdward class called NbTrolsModel. The excerpt gives the quantum circuit for the NbTrolsModel

    Below we represent them in Qubiter ASCII
    picture notation in ZL convention, for nb=3 and na=4
    [--nb---]   [----na-----]
    NbTrols (nb Controls) model:
    |0> |0> |0> |0> |0> |0> |0>
    NOTA P(x) next
    NOTA P(y|x) next
    M   M   M

    A gate |---|---Ry--%---%---%---% is called an MP_Y Multiplexor,
    or plexor for short. In Ref.1 (Qubiter repo at github), see Rosetta Stone
    pdf and Quantum CSD Compiler folder for more info about multiplexors.

If you look up the definition of a multiplexor in the Qubiter repo and references therein, you will notice that a multiplexor is a real-valued gate. Hence this model, since it only uses multiplexor gates, does not parametrize the full family of complex-valued amplitudes that are allowed in quantum mechanics. The NbTrolsModel does parametrize the whole family of possible (real-valued) probability distributions P(y|x) and P(x), where x = (q3, q2, q1, q0) and y = (q6, q5, q4), where qi is an element of 0, 1 for i=0,1,2,…6

So how can we generalize the model NbTrolsModel so that it parametrizes all possible complex-valued amplitudes too. One possibility is as follows. (call it the C_NbTrolsModel)

    |0> |0> |0> |0> |0> |0> |0>
    NOTA A(x) next
    NOTA A(y|x) next
    M   M   M

This new model contains twice as many layers as the old one. Each multiplexor gate from the old model has been followed by a “diagonal unitary” gate consisting of only % or | symbols, for instance,


. You can look up the definition of such a gate in the Qubiter repo, in the same places where you found the def of a multiplexor. In this example, D =


represents a 2^4=16 dimensional diagonal unitary matrix and I_8 =


represents the 2^3=8 dimensional unit matrix. The whole gate is I_8 \otimes D, which is a 2^7=128 diagonal unitary matrix.

To motivate what is going on in this C_NbTrolsModel model, let me claim without proof that the first two lines of the circuit parametrize a complex amplitude A(q0), the next two lines A(q1|q0), the next two A(q2|q1, q0) and so forth.

If x = (q3, q2, q1, q0) and y = (q6, q5, q4), then

A(x) = A(q3|q2, q1, q0)A(q2|q1, q0)A(q1|q0)A(q0)

A(y|x) = A(q6|q5, q4)A(q5|q4)A(q4)

A(y, x) = A(y| x) A(x).

This is just a generalization of the chain rule for probabilities which for 3 random variables is

P(c, b, a) = P(c|b, a) P(b | a) P(a)

To go from the chain rule for probabilities to the chain rule for amplitudes, we just take the square root of all the probabilities and add a bunch of relative phase factors, leading to

A(c, b, a) = A(c|b, a) A(b | a) A(a)

Warning: Note that the expansion of a multiplexor (and of a diagonal unitary) into elementary gates (cnots and single qubit rotations) contains a huge number of gates (exp in the number of controls). However, such expansions can be shortened by approximating the multiplexor (or the diagonal unitary) using, for instance, the technique of Ref.2: Oracular Approximation of Quantum Multiplexors and Diagonal Unitary Matrices, by Robert R. Tucci, https://arxiv.org/abs/0901.3851 Another possible source of simplification: just like

P(c, b, a) = P(c|b, a) P(b | a) P(a)

represents a fully connected graph which simplifies to

P(c, b, a) = P(c| a) P(b | a) P(a)

if c is independent of b, in the same way, the chain rule in these QdEdward models might simplify due to certain conditional independences in the data.

Added July 11, 2018: Of course, this can all be generalized by making q0 a qudit with d0 states, q1 a qudit with d1 states, etc. Qudit q0 can be represented by n0 qubits, where n0 is the smallest int such that d0 ≤ 2^n0, same for qudit q1, q2, etc.

In Qubiter, the Quantum CSD Compiler decomposes an arbitrary unitary matrix into a product of multiplexors and diagonal unitaries. Qubiter also allows you to decompose multiplexors and diagonal unitaries into elementary ops (CNOTs and single qubit rotations). For example, Qubiter's CSD compiler will expand an arbitrary 3 qubit unitary matrix into the following:


Hence, a QNN is like a portion of the expansion of an arbitrary unitary matrix.

When one uses complex-valued layers, the definition of ELBO must be in terms of density matrices, not classical prob distributions.

Next Page »

Create a free website or blog at WordPress.com.

%d bloggers like this: