-
Notifications
You must be signed in to change notification settings - Fork 397
Create pauli_term_grouping_test.py #1101
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
base: master
Are you sure you want to change the base?
Conversation
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
import pandas as pd | ||
import matplotlib.pyplot as plt | ||
import seaborn as sns | ||
from typing import Dict, List, Tuple, Optional, Any |
Check notice
Code scanning / CodeQL
Unused import Note
from dataclasses import dataclass | ||
from pathlib import Path | ||
import json | ||
import warnings |
Check notice
Code scanning / CodeQL
Unused import Note
|
||
# Quantum computing imports | ||
try: | ||
import cirq |
Check notice
Code scanning / CodeQL
Unused import Note
# Quantum computing imports | ||
try: | ||
import cirq | ||
from openfermion.ops import QubitOperator, FermionOperator |
Check notice
Code scanning / CodeQL
Unused import Note
import cirq | ||
from openfermion.ops import QubitOperator, FermionOperator | ||
from openfermion.chem import MolecularData | ||
from openfermion.transforms import jordan_wigner, bravyi_kitaev, get_fermion_operator |
Check notice
Code scanning / CodeQL
Unused import Note
from advanced_pauli_grouping import ( | ||
AdvancedPauliGroupOptimizer, | ||
optimized_pauli_grouping, | ||
create_molecular_test_hamiltonian | ||
) |
Check notice
Code scanning / CodeQL
Unused import Note
Import of 'create_molecular_test_hamiltonian' is not used.
|
||
# Execution time vs improvement | ||
ax3 = axes[1, 0] | ||
scatter = ax3.scatter(df['execution_time'], df['improvement_ratio'], |
Check notice
Code scanning / CodeQL
Unused local variable Note
print(f"📊 Results available in: {suite.output_dir}") | ||
|
||
# Print summary | ||
report = suite.generate_performance_report() |
Check notice
Code scanning / CodeQL
Unused local variable Note
|
||
|
||
if __name__ == "__main__": | ||
results = main() |
Check notice
Code scanning / CodeQL
Unused global variable Note
@hofong428 thank you for this work. Please add a description to this pull request. Also, this appears to be related to your PR #1100. If that's the case, please combine the two PRs (perhaps by moving this test file to the PR) because new code contributions should have test cases anyway, and thus the files belong together. |
So.. what should I do now?
…On Sat, Aug 2, 2025 at 7:01 AM Michael Hucka ***@***.***> wrote:
*mhucka* left a comment (quantumlib/OpenFermion#1101)
<#1101 (comment)>
@hofong428 <https://github.com/hofong428> thank you for this work. There
are some failures in the CI checks, as you can see. Also, the CodeQL
scanner flagged some unused Python imports that can be removed from the
files.
—
Reply to this email directly, view it on GitHub
<#1101 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AQ34Y4MKMSBMRKCUJX4IGPL3LPWTBAVCNFSM6AAAAACCUWIII2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTCNBVHE2TMOJQGI>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
If this PR contains test cases for the contribution in PR #1100, then please add the file from this PR to PR #1100, close this PR, and continue at #1100. The problems flagged by the CI here will still need to be addressed. It is up to your preferences whether you want to address them first and then move the file to the other PR, or move the file first and then address the problems. (When you push another commit to PR #1100 to add the file, it will trigger the CI jobs to run again, and the same errors will occur there until they are addressed.) I hope I answered the question you were asking. If I misunderstood, please let me know. |
Crystal clear. Thanks for your help. I will re-submit later.
…On Sun, Aug 3, 2025 at 11:08 AM Michael Hucka ***@***.***> wrote:
*mhucka* left a comment (quantumlib/OpenFermion#1101)
<#1101 (comment)>
So.. what should I do now?
If this PR contains test cases for the contribution in PR #1100
<#1100>, then please add
the file from this PR to PR #1100
<#1100>, close this PR, and
continue at #1100 <#1100>.
The problems flagged by the CI here will still need to be addressed. It is
up to your preferences whether you want to address them first and then move
the file to the other PR, or move the file first and then address the
problems. (When you push another commit to PR #1100
<#1100> to add the file, it
will trigger the CI jobs to run again, and the same errors will occur there
until they are addressed.)
I hope I answered the question you were asking. If I misunderstood, please
let me know.
—
Reply to this email directly, view it on GitHub
<#1101 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AQ34Y4KMI7AYUTNZCP7WZWL3LV4MTAVCNFSM6AAAAACCUWIII2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTCNBWHE2DAMBVGA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
No description provided.