Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/_index.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ landing_page:
qubits = [cirq.GridQubit(i,j) for i in range(5) for j in range(5)]

# Define a circuit to run
# (Example is from the 2019 "Quantum Supremacy" experiement)
# (Example is from the 2019 "Quantum Supremacy" experiment)
circuit = (cirq.experiments.
random_rotations_between_grid_interaction_layers_circuit(
qubits=qubits, depth=16))
Expand Down
4 changes: 2 additions & 2 deletions docs/choose_hw.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ noisy simulation, using a phase damping channel (p=0.01). The charts use a log
scale. These benchmarks were all performed using qsim's native GPU and CPU
backends and do not involve sampling bitstrings (i.e. no measure gates).

![qsim runtime comparison on multipe processors: noiseless](images/qsim_runtime_comparison_noiseless.png)
![qsim runtime comparison on multipe processors: noisy](images/qsim_runtime_comparison_noisy.png)
![qsim runtime comparison on multiple processors: noiseless](images/qsim_runtime_comparison_noiseless.png)
![qsim runtime comparison on multiple processors: noisy](images/qsim_runtime_comparison_noisy.png)

### 4. If using GPUs, select a backend

Expand Down
2 changes: 1 addition & 1 deletion docs/tutorials/gcp_cpu.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ and run your code.
When your connection is ready, Colab displays a green checkmark beside the
Connected (Local) drop-down menu.

<img src="../images/colab_connected.png" alt="Google Colab Local Runtime connection windo" style="width: 62%" class="screenshot">
<img src="../images/colab_connected.png" alt="Google Colab Local Runtime connection window" style="width: 62%" class="screenshot">

The code cells in your notebook now execute on your VM instead of your local
computer.
Expand Down
2 changes: 1 addition & 1 deletion docs/tutorials/qsimcirq_gcp.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ To create the VM use the steps in sequence below:
[make a different choice](https://cloud.google.com/compute/docs/regions-zones#available).
* Choose the machine family / series: N2
* Quantum simulation requires powerful processors—the N2, N1, or C2 will work.
* But if you have your own prefences, other
* But if you have your own preferences, other
[machine types](https://cloud.google.com/blog/products/compute/choose-the-right-google-compute-engine-machine-type-for-you)
are available.

Expand Down
2 changes: 1 addition & 1 deletion jupyter/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Docker container for Jupyter with _Cirq_ and _qsim_

You can build this container with the standard build commmand.
You can build this container with the standard build command.

More details on how to use this container can be found [here](../docs/tutorials/qsimcirq_gcp.md).
2 changes: 1 addition & 1 deletion lib/channels_cirq.h
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@ inline BitFlipChannel<fp_type> bit_flip(double p) {
return BitFlipChannel<fp_type>(p);
}

} // namesapce Cirq
} // namespace Cirq

} // namespace qsim

Expand Down
9 changes: 5 additions & 4 deletions lib/fuser_mqubit.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class MultiQubitGateFuser final : public Fuser<IO> {
private:
using Base = Fuser<IO>;

// Auxillary classes and structs.
// Auxiliary classes and structs.

// Manages doubly-linked lists.
template <typename T>
Expand Down Expand Up @@ -102,7 +102,7 @@ class MultiQubitGateFuser final : public Fuser<IO> {
};

// Possible values for visited in GateF.
// Note that MakeGateSequence assignes values from kSecond to the number of
// Note that MakeGateSequence assigns values from kSecond to the number of
// gates in the sequence plus one, see below.
enum Visited {
kZero = 0, // Start value for matrix gates.
Expand Down Expand Up @@ -310,7 +310,7 @@ class MultiQubitGateFuser final : public Fuser<IO> {

LinkManager<Operation, PGate> link_manager(max_qubit1 * num_ops);

// Auxillary data structures.
// Auxiliary data structures.
// Sequence of intermediate fused gates.
std::vector<GateF> gates_seq;
// Gate "lattice".
Expand Down Expand Up @@ -365,7 +365,7 @@ class MultiQubitGateFuser final : public Fuser<IO> {
return fused_ops;
}

// Fill in auxillary data structures.
// Fill in auxiliary data structures.

if (OpGetAlternative<Measurement>(op)) {
// Measurement gate.
Expand Down Expand Up @@ -1247,3 +1247,4 @@ class MultiQubitGateFuser final : public Fuser<IO> {
} // namespace qsim

#endif // FUSER_MQUBIT_H_

2 changes: 1 addition & 1 deletion lib/gates_cirq.h
Original file line number Diff line number Diff line change
Expand Up @@ -1631,7 +1631,7 @@ inline schmidt_decomp_type<fp_type> GetSchmidtDecomp(
}
}

} // namesapce Cirq
} // namespace Cirq

} // namespace qsim

Expand Down
4 changes: 2 additions & 2 deletions lib/hybrid.h
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ struct HybridSimulator final {
for (const auto& op : ops) {
if (!OpGetAlternative<Gate>(op)) {
IO::errorf("measurement, controlled or other non-matrix gates "
"are not suported by qsimh.\n");
"are not supported by qsimh.\n");
return false;
}

Expand Down Expand Up @@ -218,7 +218,7 @@ struct HybridSimulator final {
}
break;
default:
IO::errorf("multi-qubit gates are not suported by qsimh.\n");
IO::errorf("multi-qubit gates are not supported by qsimh.\n");
return false;
}
}
Expand Down
2 changes: 1 addition & 1 deletion lib/multiprocess_custatevecex.h
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ struct MultiProcessCuStateVecEx {
}

if (num_acc_global_qubits < num_global_qubits_) {
IO::errorf("erorr: too few network layers at %s %d.\n",
IO::errorf("error: too few network layers at %s %d.\n",
__FILE__, __LINE__);
exit(1);
}
Expand Down
4 changes: 2 additions & 2 deletions lib/operation_base.h
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ const T* OpGetAlternative(const Operation& op) {
/**
* Recursively retrieves the time step from a (nested) variant.
* This function traverses the provided `op` (concrete type, pointer,
* or variant) to access the `time` memeber in the underlying `BaseOperation`.
* or variant) to access the `time` member in the underlying `BaseOperation`.
* This function handles recursive `std::variant` structures and can
* transparently dereference pointers (e.g., `std::variant<A, const B*>`
* or `std::variant<A, B*>`) to find the target value.
Expand Down Expand Up @@ -208,7 +208,7 @@ inline unsigned OpTime(const Operation& op) {
/**
* Recursively retrieves the qubit indices from a (nested) variant.
* This function traverses the provided `op` (concrete type, pointer,
* or variant) to access the `qubits` memeber in the underlying `BaseOperation`.
* or variant) to access the `qubits` member in the underlying `BaseOperation`.
* This function handles recursive `std::variant` structures and can
* transparently dereference pointers (e.g., `std::variant<A, const B*>`
* or `std::variant<A, B*>`) to find the target value.
Expand Down
4 changes: 2 additions & 2 deletions lib/qtrajectory.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class QuantumTrajectorySimulator {
* of circuits with weak noise and without measurements by reusing
* the primary trajectory results. There is an additional condition for
* RunBatch. In this case, the deferred operators after the main loop are
* still applied for the first occurence of the primary trajectory.
* still applied for the first occurrence of the primary trajectory.
* The primary Kraus operators should have the highest sampling
* probabilities to achieve the highest speedup.
*
Expand Down Expand Up @@ -361,7 +361,7 @@ class QuantumTrajectorySimulator {
if (r < cp || i == channel.kops.size() - 1) {
// Sample ith Kraus operator if r < cp
// Sample the highest probability Kraus operator if r is greater
// than the sum of all probablities due to round-off errors.
// than the sum of all probabilities due to round-off errors.
uint64_t k = r < cp ? i : max_prob_index;

DeferOps(channel.kops[k].ops, deferred_ops);
Expand Down
2 changes: 1 addition & 1 deletion lib/simulator.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ namespace qsim {
*/
class SimulatorBase {
protected:
// The follwoing template parameters are used for functions below.
// The following template parameters are used for functions below.
// H - the number of high (target) qubits.
// L - the number of low (target) qubits.
// R - SIMD register width in floats.
Expand Down
2 changes: 1 addition & 1 deletion lib/statespace_cuda.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ namespace qsim {
/**
* Object containing context and routines for CUDA state-vector manipulations.
* State is a vectorized sequence of 32 real components followed by 32
* imaginary components. 32 floating numbers can be proccessed in parallel by
* imaginary components. 32 floating numbers can be processed in parallel by
* a single warp. It is not recommended to use `GetAmpl` and `SetAmpl`.
*/
template <typename FP = float>
Expand Down
2 changes: 1 addition & 1 deletion tests/unitaryspace_avx512_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ TEST(UnitarySpaceAVX512Test, GetEntry) {
TestSetEntry<UnitarySpaceAVX512<For>>();
}

} // namspace
} // namespace
} // namespace unitary
} // namespace qsim

Expand Down
2 changes: 1 addition & 1 deletion tests/unitaryspace_avx_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ TEST(UnitarySpaceAVXTest, GetEntry) {
TestSetEntry<UnitarySpaceAVX<For>>();
}

} // namspace
} // namespace
} // namespace unitary
} // namespace qsim

Expand Down
2 changes: 1 addition & 1 deletion tests/unitaryspace_basic_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ TEST(UnitarySpaceBasicTest, GetEntry) {
TestSetEntry<UnitarySpaceBasic<For, float>>();
}

} // namspace
} // namespace
} // namespace unitary
} // namespace qsim

Expand Down
2 changes: 1 addition & 1 deletion tests/unitaryspace_sse_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ TEST(UnitarySpaceSSETest, GetEntry) {
TestSetEntry<UnitarySpaceSSE<For>>();
}

} // namspace
} // namespace
} // namespace unitary
} // namespace qsim

Expand Down
Loading