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

Checkpoint is manipulated #323

Open
elwlwlwk opened this issue Jan 19, 2025 · 1 comment
Open

Checkpoint is manipulated #323

elwlwlwk opened this issue Jan 19, 2025 · 1 comment

Comments

@elwlwlwk
Copy link
Contributor

elwlwlwk commented Jan 19, 2025

https://wandb.ai/macrocosmos/folding-openmm/runs/ig30rwe2/overview

/vali-s3-demo-do/outputs/2qdv/5HYk8DMK/5GehSP5B/2025-01-19_11-49-33/md_0_1.cpt
this checkpoint file has potential energy around -5200. but load that checkpoint and save it's state using simulation.saveState and re-run from state file, potential energy is around -1200

pdb = app.PDBFile(f"{pdb_id}/{pdb_file}.pdb")
simulation, _ = OpenMMSimulation().create_simulation(
    pdb=pdb,
    system_config=config
)

simulation.loadCheckpoint(f"{pdb_id}/md_0_1.cpt")
simulation.saveState(f"{pdb_id}/state_{sim_id}.xml")

checkpoint_energies = []
for i in range(100):
    simulation.step(100)
    energy = simulation.context.getState(getEnergy=True).getPotentialEnergy()._value
    checkpoint_energies.append(energy)
print(f"Checkpoint Energies: {checkpoint_energies}")

simulation, _ = OpenMMSimulation().create_simulation(
    pdb=pdb,
    system_config=config
)

simulation.loadState(f"{pdb_id}/state_{sim_id}.xml")
state_energies = []
for i in range(100):
    simulation.step(100)
    energy = simulation.context.getState(getEnergy=True).getPotentialEnergy()._value
    state_energies.append(energy)
print(f"State Energies: {state_energies}")

Image

@mccrindlebrian
Copy link
Contributor

We are continuing to work on this issue as we are finding that the energies are not always increasing on the state-level. Therefore, they will fail the gradient check. As such, we are going to add a different

@mccrindlebrian mccrindlebrian mentioned this issue Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants