Skip to content
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

Create workflow to replicate purpose of temp_file_renaming #64

Open
Tracked by #62
ngraymon opened this issue Jun 8, 2022 · 4 comments
Open
Tracked by #62

Create workflow to replicate purpose of temp_file_renaming #64

ngraymon opened this issue Jun 8, 2022 · 4 comments

Comments

@ngraymon
Copy link
Owner

ngraymon commented Jun 8, 2022

No description provided.

@ngraymon
Copy link
Owner Author

ngraymon commented Jun 8, 2022

Per #62 (comment) the important part of temp_file_naming was the naming of the output file (lines 1736-1745 `generate_eT_zhz_python)

    # DEBUG - temporary override
    maximum_h_rank, maximum_cc_rank, maximum_T_rank, eT_taylor_max_order, omega_max_order = truncations
    path = "./eT_zhz_eqs"
    path += f"_H({maximum_h_rank})"
    path += f"_P({omega_max_order})"
    path += f"_T({maximum_T_rank})"
    path += f"_exp({eT_taylor_max_order})"
    path += f"_Z({maximum_cc_rank})"
    path += ".py"

and the looping over the different numbers in _glue_.py

for p, e, z in it.product(
    [2, 4],
    [1, 2, 3, 4],
    [1, 2, 3],
):

    # for the 'eT_z_t ansatz' only
    maximum_h_rank = 2
    maximum_cc_rank = z  # max order of Z
    maximum_T_rank = 1  # max order of T
    eT_taylor_max_order = e  # Taylor expansion of eT
    omega_max_order = p  # max order of projection operator

    # need to have truncation of e^T
    eT_z_t_truncations = maximum_h_rank, maximum_cc_rank, maximum_T_rank, eT_taylor_max_order, omega_max_order

    switch = 4

    if switch == 1:
        generate_latex_files(
            eT_z_t_truncations,
            only_ground_state=True,
            remove_f_terms=False,
            thermal=False,
            file='eT_z_t ansatz'
        )
    if switch == 2:
        generate_latex_files(
            truncations,
            only_ground_state=False,
            remove_f_terms=False,
            thermal=False,
            file='z_t ansatz'
        )
    if switch == 3:
        generate_latex_files(
            truncations,
            only_ground_state=True,
            remove_f_terms=False,
            thermal=False,
            file='full cc'
        )

    if switch == 4:
        generate_eT_zhz_python(eT_z_t_truncations, only_ground_state=True)
        # generate_full_cc_python(truncations, only_ground_state=True)

    print("We reached the end of main")

@ngraymon
Copy link
Owner Author

ngraymon commented Jun 8, 2022

Really the purpose of this branch could simply be replicated by having a workflow which generates these files and zips them up as a release? artifact? somewhere for download? maybe in the repo in non-package folder (so not stored on pypi but accessible on the github page?)
But that might be a lot of code change, unnecessarily ...? So probably just a zip file?

@ngraymon
Copy link
Owner Author

ngraymon commented Jun 8, 2022

This might be relevant https://github.com/marketplace/actions/easy-zip-files

@ngraymon
Copy link
Owner Author

ngraymon commented Jun 8, 2022

Just pushed branch storage_generated_einsum_code which includes the files zipped up from temp_file_naming we can delete that branch now @lhprice

@ngraymon ngraymon changed the title temp_file_naming Create workflow to replicate purpose of temp_file_renaming Jun 8, 2022
@lhprice lhprice linked a pull request Jun 28, 2022 that will close this issue
@lhprice lhprice removed a link to a pull request Jun 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant