Skip to content

Commit b25c74e

Browse files
Correct output shape in EstimatorQNN tutorial 01 (backport #982) (#983)
* Correct output shape in `EstimatorQNN` tutorial (#982) (cherry picked from commit 7b57913) * Change `self._num_features` in ValueError message (backport #981) (#984) (#988) * Correct `self._num_features` in ValueError (#981) (cherry picked from commit 56bbed0) * Update copyright in `base_kernel.py` --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --------- Co-authored-by: Edoardo Altamura <[email protected]> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
1 parent 05e8962 commit b25c74e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

docs/tutorials/01_neural_networks.ipynb

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -477,7 +477,9 @@
477477
"id": "7fba01a3",
478478
"metadata": {},
479479
"source": [
480-
"For the `EstimatorQNN`, the expected output shape for the forward pass is `(1, num_qubits * num_observables)` where `1` in our case is the number of samples:"
480+
"For the `EstimatorQNN`, the forward pass returns an array of shape `(batch_size, num_observables)\n",
481+
"`, where `batch_size` is the number of input samples (1 in our case) and `num_observables` is the \n",
482+
"length of the observables list."
481483
]
482484
},
483485
{
@@ -563,7 +565,7 @@
563565
"id": "3612ff46",
564566
"metadata": {},
565567
"source": [
566-
"For the `EstimatorQNN`, the expected output shape for the forward pass is `(batch_size, num_qubits * num_observables)`:"
568+
"In `EstimatorQNN`, the forward pass returns an array of shape `(batch_size, num_observables)`, where `batch_size` is the number of input samples and `num_observables` is the length of the observables list.:"
567569
]
568570
},
569571
{

0 commit comments

Comments
 (0)