-
Notifications
You must be signed in to change notification settings - Fork 7
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
NIGSC changes #318
NIGSC changes #318
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @vodovozovaliza for implementing this.
I started with a quick a review even if this is still in draft.
I agree with the changes proposed by this PR.
You can find below a few comments.
tests/test_niGSC_circuitfactory.py
Outdated
@@ -41,7 +39,7 @@ def test_abstract_factory(): | |||
cfactory = CircuitFactory(1, [1, 2] * 3, qubits=[0]) | |||
with pytest.raises(NotImplementedError): | |||
for circuit in cfactory: | |||
print(circuit.draw()) | |||
circuit.draw() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could probably be removed I think
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## simplify_builder #318 +/- ##
=================================================
Coverage 38.04% 38.04%
=================================================
Files 42 42
Lines 2802 2802
=================================================
Hits 1066 1066
Misses 1736 1736
Flags with carried forward coverage won't be shown. Click here to find out more. |
@andrea-pasquale @wilkensJ this is ready for review |
for more information, see https://pre-commit.ci
circuit_init_kwargs = deepcopy(circuit.init_kwargs) | ||
del circuit_init_kwargs["nqubits"] | ||
bigcircuit = Circuit(self.nqubits, **circuit_init_kwargs) | ||
bigcircuit.add(circuit.on_qubits(*self.qubits)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe this is clearer? I think that I is just a different taste, right?
circuit_init_kwargs = deepcopy(circuit.init_kwargs)
circuit_init_kwargs['nqubits'] = self.nqubits
bigcircuit = models.Circuit(**circuit.init_kwargs)
bigcircuit.add(circuit.on_qubits(*self.qubits))
) | ||
) | ||
fig_traces.append( | ||
go.Scatter( | ||
x=x_fit, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to put the fitting parameters in the label of the fit? If there are more than 2 plots I think the graphic is easier to read and to interact with.
@@ -137,13 +134,14 @@ def post_processing_sequential(experiment: Experiment): | |||
# After the row by row execution of tasks comes the aggregational task. Something like calculation | |||
# of means, deviations, fitting data, tasks where the whole data as to be looked at, and not just | |||
# one instance of circuit + other information. | |||
def get_aggregational_data(experiment: Experiment) -> pd.DataFrame: | |||
def get_aggregational_data(experiment: Experiment, ndecays: int = 2) -> pd.DataFrame: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How can the number of decays be changed through a runcard?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This parameter is not used in the runcards for now, but can be used to redo the fitting of the same experiment
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @vodovozovaliza.
You can find below a few comments.
I think that we should be able to merge this PR today.
src/qibocal/web/static/styles.css
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This modifications also affect the report generated by the low level routines.
Moving the table to the left is not ideal for the routine which include more than one plot.
I believe this is out of the scope of this PR, we could discuss about the report generation in a separate PR/issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried it with the routines from runcard/actions_qq.yml (a simulation) and for me it looked fine, the only change here is that it is not centered anymore and there is a bit of more whitespace between the columns.
It would be nice if you could try to generate reports with the new css settings and if something is not readable anymore I totally agree to not implement that.
Otherwise, when the table has only a 30% width our fitting parameters are in two lines and that does influence how they are read, also, it takes a lot of space, so if there are more than lets say 5 lines the breaking does make it harder to read. The 50% was as a bit arbitrary, maybe 40% would also do that, or the margin to the left can be more, that was also more of a try and error, I am very open for new ideas here.
I totally agree though that the centered looks more nice:
But it does not do any harm if it is not centered anymore:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have a problem only with the position of the table.
If you run for example t1 with dummy it looks like this:
which personally I don't like. As you said centered looks better.
I also understand that the current rendering may not best for the RB protocols.
For single plot you could try to stretch out the plot like we do for the T1 above.
For multiple plots I think that the table in the center should look ok.
But, again we could fix this in a separate PR and we should also ask the opinion of other people.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree! This looks weird. I like the idea of putting it in another PR :)
Co-authored-by: Andrea Pasquale <[email protected]>
Co-authored-by: Andrea Pasquale <[email protected]>
Co-authored-by: Andrea Pasquale <[email protected]>
Co-authored-by: Andrea Pasquale <[email protected]>
For me this would be fine to merge with the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks @vodovozovaliza.
Checklist: