LoginSignup
1
0

More than 5 years have passed since last update.

Qiskit Terra 0.6.0

Last updated at Posted at 2018-10-07

アップデートで使えなくなったものを救出できるようにメモ。
リリースノート(https://github.com/Qiskit/qiskit-terra/releases/tag/0.6.0) の翻訳+gitでの会話から重要そうなところを引っ張ってきたものです。
加筆・修正ありましたらコメントお願いします。

まとめ・概観

(この段落は私 @tsujishinが重要そうなアップデートを主観的にまとめたものです)
0. QISKit→Qiskit 
1. QuantumProgram廃止、それに伴ういくつかの仕様変更
2. 測定結果の可視化ツールをいくつか追加/改善
3. バグ修正

追加

Schema Validation関連

まとめると「QbjValidation Error を廃止して SchemaValidationErrorというもっと汎用性の高いエラーに変えた」らしい。

  • Added SchemaValidationError to be thrown when schema validation fails (#881)
    JSON schemaが正しく記述されているのか返すものらしい。
    JSON : Java Scriptベースのデータ記述言語
    データ記述言語 : プログラムというよりもそれが参照するデータを記述するもの。Mark Downとか。
    Schema :文書やリストなどのデータ構造を定義するもの
    JSON schema : JSONのデータ構造をJSONそのもので定義するもの
  • Generalized Qobj schema validation functions for all qiskit schemas (#882).
    qobjのschema検証は、qiskit / qobjで提供されている。 現行のschemaの読み込みおよび検証では、qiskit / schemasにある他のschemaで使用できるようにする必要がある。

シミュレータ

  • Added decorator to check for C++ simulator availability (#662)
    test/python/フォルダ内のテストファイルで、ファイルの先頭にC++シミュレータが存在するかどうかチェックする。 存在しない場合は、いくつかのテストはスキップされる。重複や一貫性を避けるために、test/python/common.pyにデコレータを用意して、再利用できるようにした(?)

usability

  • It is possible to cancel jobs in non comercial backends (#687)
    商用でない(5,16qubitの)プロセッサのジョブがキャンセルできるようになった。
  • Introduced new qiskit.IBMQ provider, with centralized handling of IBMQ credentials (qiskitrc file, environment variables). (#547, #948, #1000)
  • Add OpenMP parallelization for Apple builds of the cpp simulator (#698).
  • Add parallelization utilities (#701)
  • Parallelize transpilation (#701) トランスパイラ(量子ビット配置)の並列化
  • New interactive visualizations (#765).
    いくつか可視化ツールを追加。
  • ブロッホ球
  • Cities
  • Hinton
  • Histogram(観測結果の比較などに。)
  • Paulivec(パウリ観測基底と期待値)
  • Qsphere(位相が色だったり綺麗)
  • Added option to reverse the qubit order when plotting a circuit. (#762, #786) ユーザに量子ビットの順序を反転するオプションを与える デフォルトでは、q_0ビットが上部に表示されます。 reverse_qubitオプションがTrueに設定されている場合q_Nが最上位にあり、降順になる。
  • Jupyter notebook magic function qiskit_job_status, qiskit_progress_bar (#701, #734)
  • Add a new function qobj_to_circuits to convert a Qobj object to a list of QuantumCircuit objects (#877)
    qobj_to_circuits でQobjをQuantumCircuitのリストに変換
  • Allow selective loading of accounts from disk via hub/group/project filters to IBMQ.load_accounts().
    認証周り

変更

  • Schema tests in tests/schemas/test_schemas.py replaced with proper unit test (#834).

    名称

  • Renamed QISKit to Qiskit in the documentation. (#634)
    QISKit(名称)をQiskitに変更。

    Qobj(schema)

  • Use Qobj as the formally defined schema for sending information to the devices:
    Qobjをデバイスに情報を送るschemaとして使用する。

  • introduce the qiskit.qobj module. (#589, #655)
    qiskit.qobjモジュールの紹介を追加

  • update the Qobj JSON schema. (#668, #677, #703, #709)
    Qobj JSON schemaをアップデート

  • update the local simulators for accepting Qobj as input. (#667)
    ローカルシミュレータがQobjを入力として受付るようにアップデート。

  • update the Result class. (#773)
    Result class をアップデート。具体的には、新しいスキーマと古いスキーマの両方を(少なくとも一時的に)受け入れるため、qiskit._result.Resultを更新して、クラスをスキーマから分離。

ジョブの状態を見る

  • Use get_status_job() for checking IBMQJob status. (#641)

Q network 周り

  • Q network hub/group/project credentials replaced by new url format. (#740)
    Q networkのcredentialsが新しいurlフォーマットに変更

APIとか

  • Breaking change: Jobs API simplification. (#686) Jobs APIがシンプルになった。
  • Breaking change: altered tomography APIs to not use QuantumProgram. (#818)
    トモグラフィーAPIでQuantumProgramを使用しないように変更
  • Breaking change: BaseBackend API changed, properties are now methods (#858)
  • When plot_histogram() or plot_state() are called from a jupyter notebook if there is network connectivity the interactive plots will be used by default (#862, #866)
    functions iplot_histogram (interactive js plot) とplot_histogram (for a matplotlib generated plot)が同じ機能なので可換に。
  • Breaking change: BaseJob API changed, any job constructor must be passed the backend used to run them and a unique job id (#936).

  • Add support for drawing circuit barriers to the latex circuit drawer. This requires having the LaTeX qcircuit package version >=2.6.0 installed (#764)

    LaTeXのCircuit drawerでbarrierを描くためのサポート。LaTeX 2.6.0以降が必要。

廃止予定/非推奨

  • The number_to_keep kwarg on the plot_histogram() function is now deprecated. A field of the same name should be used in the option dictionary kwarg instead. (#866)
  • Breaking change: backend.properties() instead of backend.calibration() and backend.parameters() (#870)
    バックエンドの情報を得るために使用していたbackend.calibration()backend.parametersの代わりにbackend.properties()を使用

廃止

  • Removed the QuantumProgram class. (#724) QuantumProgramでrunできなくなりました......

修正

  • Fixed get_ran_qasm methods on Result instances (#688).
    コンパイルされたQASM(ran_qasm)はQobjエンティティの一部であるにもかかわらず、Resultで必要になる。 このパッチでは、QASMをResultインスタンスにコピーして使用可能にしている。
  • Fixed probabilities_ket computation in C++ simulator (#580).
    シミュレータで確立を計算するときのバグの修正
  • Fixed bug in the definition of cswap gate and its test (#685).
    フレドキンゲートの定義がおかしかったので修正 細かく見ていくと、qasm_txt = 'cx q[2],q[1];\nccx q[0],q[1],q[2];\ncx q[2],q[1];'qasm_txt = 'cswap q[0],q[1],q[2];'に変えたらしい。
  • Fixed the examples to be compatible with version 0.5+ (#672).
    チュートリアルのプログラムの例を(それぞれ一つづつ概念を説明できるように直した/古い機能を削除した)。 例1:QuantumProgramは消去され、QuantumCircuit, QuantumRegister, ClassicalRegisterが追加された。さようならQuantum Program...
    例2:Coupling map listのチュートリアルを追加
  • Fixed swap mapper using qubits after measurement (#691).
    Swap mapper:制限量子ビット間の結合(CNOT)の制限を満たすために、swap_mapperは測定されたqubitにプログラムの量子ビットをスワップする機能
    この修正では、swap mappingを実行する前に、ゲートがないMeasurement(回路の終わりにあるmeasurement)を削除します。mappingが完了すると、Measurementが回路の最後に追加されます。 (Qobjにフラグを追加して、シミュレータにフラグを読み込ませる必要があります。)
  • Fixed error in cpp simulator for 3+ qubit operations (#698).
    複数(3以上)量子ビット演算を適用すると、シミュレータのテンソルインデックス関数にエラーがあった。 このような演算は、測定サンプリングがqubitのサブセットに対して呼び出された場合にのみ適用される。 この修正ではインデックス付け関数を修正して、n-qubit演算に対して正しく機能するようにした。
    また、この修正にはmacのビルドでOpenMP並列化を有効にするために使用できる、シミュレータ用の更新されたmakefileも含まれている。LLVM OpenMPライブラリHomebrew(brew install libomp)を使用してインストールされている場合は、Apple Xcodeでビルドする。見つからない場合はGCCでビルドし、openmpを使用しない場合はXcodeでビルドする。
  • Fixed issue with combining or extending circuits that contain CompositeGate (#710).
    composite gateがreapply()メソッドを持たないために、生成された回路を他の回路に拡張または結合することができなかった問題を解決。
  • Fixed the random unitary generation from the Haar measure (#760).
    Haar測度でのランダムユニタリー行列生成の修正。
  • Fixed the issue with control lines spanning through several classical registers (#762). kwargパラメータをLaTeX drawerに追加。 reverse_qubits:ユーザに量子ビットの順序を反転するオプションを与える デフォルトでは、q_0ビットが上部に表示されます。 reverse_qubitオプションがTrueに設定されている場合q_Nが最上位にあり、降順になる。
  • Fixed visualizations crashing when using simulator extensions (#885). このJSON表現は、解析してからQASMをアンロールして生成されました。 QASM unrollerはシミュレータ拡張をサポートしていません。
    DAGUnrollerは拡張機能をサポートしているため、DAGUnrollerはQASMの代わりに使用できる。DAGUnrollerは回路を解析するときにすべての複合ゲートを拡張する。これは回路表現には望ましくない。ここで、コンポジットゲートの拡張を避けるため、新しいフラグがDAGコンストラクタに追加される。
  • Fixed check for network connection when loading interactive visualizations (#892). インターネット接続なしでqiskitをロードするとConnectionErrorが発生する。ここでは、接続が確立できない場合、正常に終了する前のチェックを置き換えた。
1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0