-
Notifications
You must be signed in to change notification settings - Fork 3k
Defaults in TranspileConfig (now called PassManagerConfig) #3035
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 42 commits
efd1aa8
4527a17
76befce
e95a102
75ca2cd
ca3e1d2
ba39d87
203280f
eccfd27
ea8d6a2
cc393d1
24ce889
fc488b8
44677ce
b5ee757
01de59b
fe54db6
26b379e
4aeb87e
117d813
948b3d4
a909c5f
83a79d1
2f1e60e
23d1742
26d19e2
73b21c2
bbb1c45
142e298
321b906
4c98cc5
38f7c56
af9a914
5627f46
1ad6b25
1c91111
6b0b4be
cc7ddc1
187a58e
d261510
d4af0f8
3037240
2a99885
009238d
ad5bb3a
b21e0b3
70aaf6c
6dbac3b
8c5faba
a3582cc
1efe02f
58ecc5d
dacb8be
5ae9f13
a0b1755
0c13b16
cf28d29
571375f
09d0c90
9ec8679
095c0cc
34aec1e
a31a190
be7314a
66d838a
63e3e68
078979a
570c1f1
15f4dd4
fa007a0
6ed9677
7ec5ceb
08b68ea
4c87790
cef86d3
c50cf29
7d811ef
b57b28d
e1d7f10
7ad1521
b84e270
346b8ea
edc9184
ce06242
1c219ed
8d935be
a9e6825
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -12,24 +12,35 @@ | |
| # copyright notice, and modified files need to carry a notice indicating | ||
| # that they have been altered from the originals. | ||
|
|
||
| """Models for TranspileConfig and its related components.""" | ||
| """Models for PassManagerConfig and its related components.""" | ||
|
|
||
| from qiskit.transpiler.models import TranspileConfigSchema | ||
| from qiskit.transpiler.models import PassManagerConfigSchema | ||
| from qiskit.validation import BaseModel, bind_schema | ||
|
|
||
|
|
||
| @bind_schema(TranspileConfigSchema) | ||
| class TranspileConfig(BaseModel): | ||
| """Model for TranspileConfig. | ||
| @bind_schema(PassManagerConfigSchema) | ||
| class PassManagerConfig(BaseModel): | ||
| """Model for PassManagerConfig. | ||
|
|
||
| Please note that this class only describes the required fields. For the | ||
| full description of the model, please check ``TranspileConfigSchema``. | ||
| full description of the model, please check ``PassManagerConfigSchema``. | ||
|
|
||
| Attributes: | ||
| optimization_level (int): a non-negative integer indicating the | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Attributes documentation should be updated. Also, would there be value in having an object for both the
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. attributes documentation should be updated.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you make sure the module docstring has all the right info about what this new class contains.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is still not addressed. docstrings are not up to date
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed in fa007a0 |
||
| optimization level. 0 means no transformation on the circuit. Higher | ||
| levels may produce more optimized circuits, but may take longer. | ||
| """ | ||
| def __init__(self, optimization_level, **kwargs): | ||
| self.optimization_level = optimization_level | ||
| super().__init__(**kwargs) | ||
|
|
||
| def __init__(self, | ||
| initial_layout=None, | ||
| basis_gates=None, | ||
| coupling_map=None, | ||
| backend_properties=None, | ||
| seed_transpiler=None, | ||
| **kwargs): | ||
| super().__init__(initial_layout=initial_layout, | ||
| basis_gates=basis_gates, | ||
| coupling_map=coupling_map, | ||
| backend_properties=backend_properties, | ||
| seed_transpiler=seed_transpiler, | ||
| **kwargs) | ||
Uh oh!
There was an error while loading. Please reload this page.