Commit Graph

172 Commits

Author SHA1 Message Date
lyskov-ai
39671441e6 refactor(mypy): clear 8 easy rfd3 modules off the ignore ratchet (#298)
* refactor(mypy): un-ignore 5 easy-tier modules

Fix each module's single pre-existing type error with a pure annotation
or setattr change (no behavior change) and remove it from the
[[tool.mypy.overrides]] ignore_errors list:

- callbacks/train_logging: loss_trackers: dict[str, MeanMetric]
- callbacks/metrics_logging: seen_examples: set[str]
- common: setattr(wrapper, "_has_run", True) for the @wraps wrapper
- hydra/resolvers: attribute_path: str | None (body already guards)
- inference_engines/base: base_overrides: dict[str, Any]

13 modules remain on the ignore list. mypy now type-checks the 5
newly-included modules cleanly.

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>

* refactor(mypy): un-ignore 7 medium-tier modules

Resolve the type errors in and remove from the [[tool.mypy.overrides]]
ignore_errors list. Mostly narrowing / annotation fixes; two deliberate
type-honesty fixes flagged below.

- utils/weights: lowercase `any` -> `Any` in _PatternPolicyMixin (4x);
  assert-narrow fallback_policy at the call site (matches get_policy idiom)
- model/layers/blocks: class-level w/b: torch.Tensor for the registered
  buffers (avoids nn.Module's Tensor | Module __getattr__ fallback)
- utils/components: is-None narrowing + tip_names local in get_name_mask's
  TIP branch (exists() can't narrow for mypy); drop orphaned exists import
- utils/logging: str(field) for the tree key; assign to a new hparams local
  rather than reassigning the typed cfg param
- foundry_cli/download_checkpoints: guard on `hasher is not None`;
  total_size = 0.0 for the float accumulation
- training/schedulers: SchedulerConfig.scheduler is now a required field
  (was = None, but documented required and assumed non-None everywhere)
- utils/xpu/xpu_accelerator: name @property -> @staticmethod to match
  lightning's Accelerator ABC

6 hard-tier modules remain on the ignore list.

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>

* refactor(mypy): un-ignore metrics/metric module

Fix the 11 type errors in foundry.metrics.metric and remove it from the
[tool.mypy.overrides] ignore_errors list (5 hard-tier modules remain).

- str(name) coercion of DictConfig.items() keys (str|bytes|int|... union)
- exists() -> 'is not None' narrowing; drop orphaned atomworks import
- widen compute_from_kwargs -> dict|list and kwargs_to_compute_args -> dict|None
  to match the actual returns / documented contract (callers already handle them)
- three type: ignore[arg-type] on nested_dict.get/getitem for an upstream
  atomworks annotation bug (param typed dict[tuple,...] but navigated as nested
  dict[str,Any]); warn_unused_ignores will flag them if upstream is fixed

No behavior change. All gates green (ruff, mypy 41 files, pytest 27 passed).

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>

* refactor(mypy): un-ignore utils/{ddp,rigid,datasets}

Clear the three remaining foundry.utils.* modules off the mypy ignore_errors list (47 errors: ddp 12, rigid 16, datasets 19). Type-honesty and annotation fixes only, no behavior change: narrow DictConfig|dict params to DictConfig where attribute access requires it (item access kept where a plain-dict default is real), honest int|None / Tensor|None widenings, variable renames to avoid type-reuse, str() coercion of DictConfig keys, the file's own if/elif/else narrowing pattern, and documented type: ignore / cast for genuine torch and atomworks stub limitations. Two hard-tier modules remain (callbacks/health_logging, trainers/fabric).

Co-authored-by: lyskov-ai <277346777+lyskov-ai@users.noreply.github.com>

* refactor(mypy): un-ignore callbacks/health_logging

Clear foundry.callbacks.health_logging off the mypy ignore_errors list
by fixing its 23 type errors (annotation / type-honesty only, no
behavior change):

- import the stdlib 'types' module directly instead of relying on
  'from typing import types' (worked at runtime but fragile/untyped)
- replace 'callable'-used-as-a-type with Mapping[str, Callable[..., Any]]
  on the stat/histogram dict params and Callable[..., bool] | None on the
  filter params; annotate the two MappingProxyType default constants to
  match
- annotate the _hooks / _temp_cache / _cache instance vars
- make implicit-Optional defaults explicit (... | None) on the two
  plot_tensor_* helpers, matching their is-not-None guards
- in plot_tensor_hist, replace two type-changing param reassignments with
  equivalent always-set locals (display_values, step_labels)

Only trainers/fabric remains on the ignore list.

Co-authored-by: lyskov-ai <277346777+lyskov-ai@users.noreply.github.com>

* refactor(mypy): un-ignore trainers/fabric (ratchet complete)

Clear foundry.trainers.fabric (the last and largest module) off the
mypy ignore_errors list and remove the now-empty override block. The
ratchet ignore list is now empty: all of src/foundry + src/foundry_cli
type-checks with no per-module exemptions.

Fixes are annotation / type-honesty only, no behavior change:

- annotate self.state as dict[str, Any] (a heterogeneous, dynamically-
  keyed training-state bag, also merged with arbitrary checkpoint keys);
  this collapses ~69 union-attr/operator/arg-type errors. Also annotate
  default_state and declare _current_train_return (set by subclass
  training_step implementations).
- dataloader types: Fabric.setup_dataloaders is stub-typed to return
  DataLoader | list[DataLoader], so cast its single-loader results to
  DataLoader and change train_loop/validation_loop params from
  _FabricDataLoader to DataLoader (drop the now-unused import).
- precision: widen the param to str | int | None (the body sets it None
  when an XPU plugin takes over), cast to the guarded Literal at the
  XPUMixedPrecision call, and add one documented type: ignore[arg-type]
  where our public API is wider than Fabric's precision Literal.
- narrow the parameter-freezing guard to direct attribute access; type
  get_latest_checkpoint as Path | None (matching its returns) with a
  cast at the single caller; drop a stale type: ignore.

Co-authored-by: lyskov-ai <277346777+lyskov-ai@users.noreply.github.com>

* chore(mypy): bring models/rfd3 into scope behind an ignore_errors ratchet

Add models/rfd3/src/rfd3 to [tool.mypy].files so the rfd3 model package
is type-checked by the standard gate (mypy now covers 99 files: foundry +
rfd3). Seed a fresh [[tool.mypy.overrides]] ignore_errors ratchet listing
the 32 rfd3 modules with pre-existing type errors (194 total), mirroring
the original src/foundry bootstrap; the 26 already-clean rfd3 modules are
type-checked immediately. Modules are cleared from the ratchet one slice
at a time in follow-up work.

Config only, no code changes. rfd3 is an editable install, so imports
resolve without an added mypy_path.

Co-authored-by: lyskov-ai <277346777+lyskov-ai@users.noreply.github.com>

* refactor(mypy): clear 8 easy rfd3 modules off the ignore ratchet

First slice of clearing the models/rfd3 mypy ratchet: the 8 modules with
a single error each (32 -> 24 remaining on the ignore_errors list). mypy
now type-checks 34 rfd3 modules.

Annotation / type-honesty only, no behavior change:
- block_utils: -> torch.LongTensor -> torch.Tensor (.long() is stub-typed
  Tensor; sibling helpers already return Tensor)
- hbonds_hbplus: corrected calculate_hbonds's stale return annotation to
  match the actual (AtomArray, list[dict], int) return
- inference/parsing: malformed pydantic np.ndarray[np.bool_] ->
  np.ndarray[Any, np.dtype[np.bool_]]
- chunked_pairwise: assert _sm_cached is not None in the cache fast path
  (populated together with the already-narrowed _sl_cached)
- rasa: documented type: ignore[list-item] (atomworks Transform types
  requires_previous_transforms as list[str]; class refs are accepted)
- ncaa_transforms / design_metrics / testing_utils: var-annotated dicts
  (+ a missing 'from typing import Any')

Co-authored-by: lyskov-ai <277346777+lyskov-ai@users.noreply.github.com>

---------

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>
Co-authored-by: Hope Woods <hope.woods@omsf.io>
2026-06-03 16:13:41 -05:00
lyskov-ai
b69bed5e4c test: bootstrap mypy + pytest + coverage CI gates (#284)
* test: bootstrap mypy + pytest + coverage CI gates

Wire up the tooling the upcoming test/annotation/refactor work depends on:

- Add mypy>=1.13 to [dev] and a lenient [tool.mypy] config scoped to
  src/foundry + src/foundry_cli (ignore_missing_imports, no
  disallow_untyped_defs). The 14 modules with pre-existing type errors
  are pinned via [[tool.mypy.overrides]] ignore_errors=true and listed
  as the ratchet target — fix and remove, never add.
- Add [tool.pytest.ini_options] (testpaths=["tests"], --strict-markers
  --strict-config) and [tool.coverage.*] (source = src/foundry +
  src/foundry_cli, branch = true) for opt-in gap finding.
- Add .github/workflows/test.yaml with mypy and pytest jobs running on
  the same triggers as lint_production.yaml. Top-level tests/ only;
  per-model tests under models/*/tests/ may require GPU and checkpoints
  and stay out of CI for now.

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>

* test(mypy): extend ignore list with 4 modules CI surfaced

Local sanity-check ran mypy without foundry installed, so torch /
lightning resolved to `Any` and errors that depend on knowing those
types stayed invisible. First CI run installed the full deps and
surfaced 6 errors in 4 additional modules:

  foundry.model.layers.blocks
  foundry.training.schedulers
  foundry.utils.logging
  foundry.utils.xpu.xpu_accelerator

Same ratchet contract as the original 14: do not add, only remove
(after fixing the errors and removing `ignore_errors = true`).

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>

* style: ruff format 2 pre-existing files unrelated to bootstrap

These files have been failing `ruff format --check` on production HEAD
(merged via #275 and #281 without a pre-commit run). They block the
existing `lint_production` workflow on every PR, including this
bootstrap. Strictly out of scope for 0001 — kept in a separate commit
so it can be cherry-picked or reverted cleanly.

  models/rfd3/src/rfd3/inference/input_parsing.py
  models/rfd3/tests/test_partial_diffusion.py

No semantic changes — `ruff format` output only.

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>

* ci: run test workflow on all pull requests

Drop the base-branch filter on the pull_request trigger so PRs targeting
stacked task branches are gated too, not only PRs into the mainline branches.

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>

* Update test.yaml to remove pull_request_target

Removed pull_request_target event from workflow.

---------

Co-authored-by: Sergey Lyskov <sergey.lyskov@jhu.edu>
Co-authored-by: Sergey Lyskov <3302736+lyskov@users.noreply.github.com>
2026-06-02 13:51:28 -05:00
Jonathan Funk
cd4d94fb0c Issue with ORI token in partial diffusion (#275)
fix(rfd3): respect ori_token and center on diffused-region COM in partial diffusion

`_set_origin` for partial diffusion previously hard-coded `ori_token=None`
and `infer_ori_strategy="com"`, with two consequences:

1. The user-supplied `ori_token` (and `infer_ori_strategy`) was silently
   dropped. Documented behavior is that the diffused-region COM ends up
   within ~5 A of the user's ORI token, but in partial diffusion mode any
   value passed by the caller had no effect on the output coordinates.

2. The default centering used the COM of the entire input (motif +
   diffused region) instead of the diffused-region COM. The training
   pipeline uses `center_option=diffuse` (see
   `configs/datasets/design_base.yaml`), so the model expects the
   diffused region's COM at the origin. Joint-COM centering puts the
   diffused region far from origin in a frame the model never saw at
   training, which biases denoising to drag the diffused region toward
   the motif COM. On asymmetric systems (large target, small binder),
   the binder visibly drifts toward the target with increasing
   `partial_t` -- consistent with the "binder winds around target"
   reports.

This change updates partial-diffusion centering to:
  1. Skip centering for symmetric structures (unchanged).
  2. Honor user-supplied `ori_token` / `infer_ori_strategy` if provided.
  3. Otherwise center on the diffused-region COM (matches training).

Empirical verification on a CD3E binder showed the inward pull at
partial_t=15 dropped from -4.46 A (joint-COM centering) to -0.46 A
(diffused-COM centering). On a thelma enzyme run, supplying
`ori_token=[50,0,0]` now shifts the output frame by -50 A in x as
expected (was 0 A before), while fixed-atom RMSD stays at machine
precision (~0.02 A Kabsch).

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-24 20:19:43 -07:00
Raktim Mitra
07e9ace471 Fix: stop dropping nucleic acid residues in partial diffusion (#281)
* stop dropping nucleic acid residues in partial diffusion

* stop dropping nucleic acids in partial diffusion rfd3na

* ruff format

* Update input_parsing.py ruff format
2026-05-23 14:25:13 +02:00
Rafael Brent
cee116dc55 fix: infer ori edge case (#273)
* fix: correct bug when inferring ori from hotspots that occurs when the original hotspot COM is near (0,0,0)

* fix:rafi hotspot fix for inference.py for rfd3na

---------

Co-authored-by: Rafi Brent <rafi.brent@gmail.com>
Co-authored-by: Raktim Mitra <timkartar7879@gmail.com>
2026-04-23 13:31:16 -07:00
Raktim Mitra
2e3f2edde2 rfd3na (#269)
* rfd3na

* ruff check fix

* ruff format

* handle P suffix from fonudry components update

* simplify p suffix handling and fix demo.json (was brokem in foundry due to ligand chain allow issue)

* clean; remove extraneous files

* main doc cleanup; training fix

* rnasep png

* add white background to png

* try jpg as png getting cropped

* atom23 gif

* Update README.md

* foundry install

* no background multipolymer

* Update README.md

* ruff format

---------

Co-authored-by: Raktim Mitra <raktim@localhost>
Co-authored-by: Rohith Krishna <rohith@localhost>
Co-authored-by: Raktim Mitra <raktim@digs>
Co-authored-by: Raktim Mitra <raktim@digs.ipd.uw.edu>
2026-04-16 09:52:02 -07:00
Rachel Clune
b071919caa Docs rfd3 instsallation tutorial (#262)
* Adding the RFD3 installation guide from the Tutorial Hackathon

* Update RFdiffusion3_installation_tutorial.md

Edits based on communications with the original author (Florian) along with minor corrections and formatting changes.
2026-04-08 08:26:11 -07:00
Jasper Butcher
7dd7b31a0a Improve PTM bond handling in RFdiffusion3 (#256)
* Improve PTM bond handling in RFdiffusion3 input parsing

Replace the old _restore_bonds_for_nonstandard_residues approach with a
more robust bond restoration system that properly handles unindexed
components, backbone-like bonds for non-standard residues (PTMs), and
cross-residue bond preservation from source structures. Adds the legacy
counterpart and regression tests for both code paths.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Apply ruff formatting to PTM bond handling files

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Remove is_motif_atom guards from legacy input parsing

The bare is_motif_atom annotation is being abolished; remove the
guards that were adding it when missing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Gate bond restoration behind nonstandard-residue check

Only run _restore_component_bonds, _add_backbone_bonds_for_nonstandard_residues,
and _sort_bonds when the source structure actually has backbone connections
to nonstandard residues.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-04 22:11:59 -07:00
Jasper Butcher
b5395e43a8 Fix ligand res_id offset to match AF3 convention (#261)
* Fix ligand res_id offset to match AF3 output convention

RFD3 was offsetting ligand res_id values from the protein max, causing
(chain_id, res_id, atom_name) pairing to fail against AF3 predictions
which always start ligand res_id at 1. Replace the offset with dense
rank-based per-chain renumbering (1, 2, ...) and add a chain A
validation with an override option (allow_ligand_on_chain_a).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Generalize chain validation to all existing chains

Rename allow_ligand_on_chain_a → allow_ligand_on_existing_chain and
check against all chains already present in the built atom array,
not just chain A.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Error on multiple ligands per chain; preserve gaps in override mode

When allow_ligand_on_existing_chain is False, raise an error if
multiple ligand residues share the same chain. Reset res_id min to 1
per chain, preserving relative gaps when ligands share a chain
(override mode).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Use legacy res_id offset when allow_ligand_on_existing_chain is True

The override path now matches the old behaviour (offset from protein
max res_id). The default path (separate chains) sets each ligand
chain's res_id to 1.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Note in errors that override restores old behaviour

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-04 21:49:41 -07:00
Jasper Butcher
54a8d721c1 Expose n_recycle as inference sampler parameter (#259)
* Expose n_recycle as inference sampler parameter and improve docs

The n_recycle parameter was previously hardcoded in the diffusion module
config and not overridable at inference time. This exposes it through the
inference sampler so users can control recycling iterations via CLI
(e.g. inference_sampler.n_recycle=3). Also adds num_timesteps and
n_recycle to the "Other CLI Options" docs section, and makes the
InputSpecification reference more prominent in the README.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Apply suggestions from code review

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-04-04 16:37:44 -07:00
Jasper Butcher
9fa9ba2f27 Add MPS (Apple Silicon) support for RFD3, RF3, and ProteinMPNN (#260)
Adds support for running inference on Apple Silicon MPS devices.

Key changes:
- Handle bfloat16 -> float32 fallback on MPS (bfloat16 unsupported)
- Add scatter_mean utility with MPS fallback (index_reduce unsupported)
- Guard masked_scatter_/boolean indexing in block_utils with MPS paths
- Use expand (zero-copy) on CUDA/CPU, repeat (contiguous) on MPS for
  torch.where compatibility
- Add .contiguous() calls for scatter/gather ops that require it on MPS
- Replace hardcoded "cuda" in autocast dtype queries with device_of()
- Store torch.linalg.det result before torch.sign to avoid MPS in-place
  op issues on autograd graph leaves
- Auto-detect MPS accelerator and enforce float32 precision
- Add MPS installation instructions to README

Based on work by @fnachon in PR #257 with additional fixes:
- expand/repeat if-else to avoid O(L^2) allocation on non-MPS backends
- ruff 0.8.3 formatting to pass CI lint checks

Co-Authored-By: fnachon

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-04 16:36:44 -07:00
kaistroh
2b938016f4 Optimize attention computation with local window bias (#254)
Refactor attention mechanism to compute pair bias within local windows, avoiding large tensor operations.
2026-04-04 15:04:27 -07:00
Jane
c5a9fbefde Fix broken PPI tutorial link in RFdiffusion3 README (#252)
The tutorial URL was missing the tutorials/ subdirectory. Updated to point to the correct path at models/rfd3/tutorials/ppi_design_tutorial.html
2026-03-26 10:08:05 -07:00
Rachel Clune
257d20ca88 Docs: Intermediate enzyme design tutorial (#250)
* Uploading and editing the first enzyme design tutorial from the Tutorial Hackathon

This tutorial was written by Johannes and Florian and is meant to be an intermediate enzyme design tutorial.

* Updated draft of Intermediate Enzyme Design Tutorial

* Added explanations for the fixed atom and unfixed motif constraints
* Added more detail about the metrics to quickly determine if a design is 'good'

* Adding example input and output files

- Removal of 1mg5.cif and 1mg5_motif.pdb.cif as they are not necessary for the tutorial.
- Creation of an `outputs.zip` that contains example output files for this tutorial
- Edits to the tutorial document to point to these files.

* Updated description of catalytic structure

Updated the description of the catalytic structure to better cite the literature.
2026-03-24 13:37:21 -07:00
Rachel Clune
6ab4add581 Fixed broken links in tutorials (#242) 2026-03-12 19:50:52 -07:00
Rachel Clune
146c2be7ac Creation of a NA binder tutorial (#232)
* Docs: Installation FAQ space and minor RFD3 docs updates

Installation FAQ: created a document to specify any common installation issues and questions. Should be continuously updated based on logged issues and questions. Not specific to any model.

RFD3:
- changed the checkpoint files specified in the examples to rfd3_latest.ckpt
- updated information in input.md to clarify information based on recent issues that had been submitted

* Docs: Symlinks for RF3 and MPNN docs, RFD3 README minor edits

RF3 and MPNN: folders, index files, and symlinks were created in order to provide space for eventual RF3 and MPNN docs.

Several small changes in the RFD3 README to improve readability and  add a pointer to the PPI tutorial as a starting point for someone new to RFdiffusion tools.

* First draft of enzyme design tutorial. Minor typo fixes in other documents.

* First draft of nucleic acid binder tutorial, minor edits to the other tutorials

* Completed enzyme design tutorial, removal of NA binder tutorial from index

Made changes based on edits from Saman, added images, and created zip file containing sample outputs for an enzyme design tutorial.

I am waiting on edits for the NA binder design tutorial, so for now I have removed it from the documentation index.

* First drafts of content for NA binder design tutorial

This tutorial is being created in collaboration with Raktim Mitra.

* Adding images to NA binder design tutorial

* Final draft of NA binder tutorial

* Create unfix.zip

* Updated images for na binder tutorial
2026-03-12 19:36:36 -07:00
Nathaniel Corley
4686f7300c fix: reference conformers (#235) 2026-03-06 12:56:10 -08:00
Rachel Clune
38d0989cb7 Docs: RF3 README update and moving RF3 examples (#216)
* RF3 README update and moving RF3 examples

I updated the RF3 README for installation instructions that matched the RFD3 installation instructions. For the first example, I improve the instructions for running and fixed the output file descriptions to match what is now output by running the example. I commented out the 'Templating a Small Molecule' section because many of the files in that section were not present in the repository. The rest of the changes were mostly typo fixes.

 I moved the examples from `foundry/docs/releases` to `foundry/models/rf3/docs` to match the organization of RFD3. The changes made to the JSON files just reflect this change of location.

* Changed paths in example JSON files to point to new RF3 examples location

* Updated the landing page for the RF3 documentation so that it links out to the README
2026-02-27 15:35:02 -08:00
Rachel Clune
2f905c59b4 Delete models/rfd3/docs/enzyme_tutorial_files directory
Accidentally duplicated in the last commit
2026-02-25 21:29:58 -08:00
Aiko
290b2fd0bb fix: weight initialization bug in chunked P_LL (#229)
- Also cache static projections for speedup
2026-02-25 16:29:51 -08:00
Rachel Clune
99a0cb773a Enzyme Design Tutorial (#210)
* Docs: Installation FAQ space and minor RFD3 docs updates

Installation FAQ: created a document to specify any common installation issues and questions. Should be continuously updated based on logged issues and questions. Not specific to any model.

RFD3:
- changed the checkpoint files specified in the examples to rfd3_latest.ckpt
- updated information in input.md to clarify information based on recent issues that had been submitted

* Docs: Symlinks for RF3 and MPNN docs, RFD3 README minor edits

RF3 and MPNN: folders, index files, and symlinks were created in order to provide space for eventual RF3 and MPNN docs.

Several small changes in the RFD3 README to improve readability and  add a pointer to the PPI tutorial as a starting point for someone new to RFdiffusion tools.

* First draft of enzyme design tutorial. Minor typo fixes in other documents.

* First draft of nucleic acid binder tutorial, minor edits to the other tutorials

* Completed enzyme design tutorial, removal of NA binder tutorial from index

Made changes based on edits from Saman, added images, and created zip file containing sample outputs for an enzyme design tutorial.

I am waiting on edits for the NA binder design tutorial, so for now I have removed it from the documentation index.

* Removing file related to in-progress NA binder tutorial

* Removing file related to in-progress NA binder tutorial

* Final version of the enzyme design tutorial

Made small edits, created example files.

* Resolving merge conflicts
2026-02-25 16:13:05 -08:00
David Hyunyoo Jang
9f609e8758 Docs: update repository URL in README (#226)
fix: update repository URL in README
2026-02-25 14:39:22 -08:00
Raktim Mitra
3b262b742b Update na_binder_design.md (#230)
UPdating the same minor change int the complex example in the .md file as did for the .json earlier
2026-02-25 14:34:33 -08:00
Rachel Clune
4a70f0ef93 Docs: Designability vs. Diversity (#220)
* Docs: Installation FAQ space and minor RFD3 docs updates

Installation FAQ: created a document to specify any common installation issues and questions. Should be continuously updated based on logged issues and questions. Not specific to any model.

RFD3:
- changed the checkpoint files specified in the examples to rfd3_latest.ckpt
- updated information in input.md to clarify information based on recent issues that had been submitted

* Docs: Symlinks for RF3 and MPNN docs, RFD3 README minor edits

RF3 and MPNN: folders, index files, and symlinks were created in order to provide space for eventual RF3 and MPNN docs.

Several small changes in the RFD3 README to improve readability and  add a pointer to the PPI tutorial as a starting point for someone new to RFdiffusion tools.

* First draft of enzyme design tutorial. Minor typo fixes in other documents.

* First draft of nucleic acid binder tutorial, minor edits to the other tutorials

* Completed enzyme design tutorial, removal of NA binder tutorial from index

Made changes based on edits from Saman, added images, and created zip file containing sample outputs for an enzyme design tutorial.

I am waiting on edits for the NA binder design tutorial, so for now I have removed it from the documentation index.

* Removing file related to in-progress NA binder tutorial

* Removing file related to in-progress NA binder tutorial

* Update ppi_design_tutorial.md

- Added information about useful CLI arguments
- Cleaned up the introduction
- Added section for what one might do with the designs from RFD3
- Added a note about hotspot residues also being in the `contig` (information from Rafi's TTT talk)
- Fixed minor sphinx heading issue

* Reorganizing RFD3 documentation

Reorganized files into an `examples` and a `tutorials` folders to clean up the RFD3 docs folder and align its organization with the RF3 docs folder. Any edits made in the files are related to changing the paths to reflect these changes.

* Docs: Designability vs. Diversity document

Created a document describing the settings that can impact the designability and diversity of structures output by RFdiffusion3, the information is based on the talk Rafi gave at Tech Tea Time in January.

* Minor grammar fixes in designability vs diversity document

* Update models/rfd3/docs/tutorials/ppi_design_tutorial.md

Co-authored-by: Rafael Brent <105883594+RafiBrent@users.noreply.github.com>

* Update models/rfd3/docs/tutorials/enzyme_design_tutorial.md

Co-authored-by: Rafael Brent <105883594+RafiBrent@users.noreply.github.com>

* Update models/rfd3/docs/designability_vs_diversity.md

Co-authored-by: Rafael Brent <105883594+RafiBrent@users.noreply.github.com>

* Update models/rfd3/docs/designability_vs_diversity.md

Co-authored-by: Rafael Brent <105883594+RafiBrent@users.noreply.github.com>

---------

Co-authored-by: Jasper Butcher <66851659+Ubiquinone-dot@users.noreply.github.com>
Co-authored-by: Rafael Brent <105883594+RafiBrent@users.noreply.github.com>
2026-02-24 10:50:29 -08:00
Raktim Mitra
3294b06cc6 Update na_binder_design.json (#223) 2026-02-19 09:14:49 -08:00
Jasper Butcher
ea05d5939b Fix ligand annotatitions (#219) 2026-02-17 14:06:42 -08:00
Raktim Mitra
4f26b2d46a fix: switch to tmpdir otherwise hb2 won't be found (#218)
Co-authored-by: Raktim Mitra <raktim@localhost>
2026-02-17 14:03:21 -08:00
Rachel Clune
b100462717 Fix chain break representation in input.md
Updated the documentation for the 'contig' field to correct the representation of chain breaks from '\0' to '/0'.
2026-02-12 09:45:38 -08:00
Rohith Krishna
976018840d remove reliance of rooutils for pip installed case (#200)
Co-authored-by: Rohith Krishna <rohith@digs>
2026-02-04 19:04:54 -08:00
Rachel Clune
38a83a97b1 Docs: PPI tutorial updates, RF3 and MPNN docs placeholders, minor edits (#195)
* Docs: Installation FAQ space and minor RFD3 docs updates

Installation FAQ: created a document to specify any common installation issues and questions. Should be continuously updated based on logged issues and questions. Not specific to any model.

RFD3:
- changed the checkpoint files specified in the examples to rfd3_latest.ckpt
- updated information in input.md to clarify information based on recent issues that had been submitted

* Docs: Symlinks for RF3 and MPNN docs, RFD3 README minor edits

RF3 and MPNN: folders, index files, and symlinks were created in order to provide space for eventual RF3 and MPNN docs.

Several small changes in the RFD3 README to improve readability and  add a pointer to the PPI tutorial as a starting point for someone new to RFdiffusion tools.
2026-02-02 15:33:04 -08:00
Rafael Brent
f682e8c801 fix: correct typo (#194)
Co-authored-by: Rafi Brent <rafi.brent@gmail.com>
2026-02-02 11:11:58 -08:00
Rafael Brent
857b6fbb51 docs: clarify is_non_loopy defaults (#193)
Co-authored-by: Rafi Brent <rafi.brent@gmail.com>
2026-02-02 10:55:23 -08:00
Aiko
c35837e279 fix: revert symmetry related code to the point that was stable (#179) 2026-01-22 23:50:54 -08:00
Jasper Butcher
06b19bdce7 Fix hbond calculation to remove produced file (#178)
* Fix hbond calculation to remove produced file

* Update models/rfd3/src/rfd3/transforms/hbonds_hbplus.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update models/rfd3/src/rfd3/transforms/hbonds_hbplus.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-22 18:37:46 -08:00
Rohith Krishna
a79cb953e2 Update inference command path in README.md (#169) 2026-01-16 14:51:57 -08:00
Simon Mathis
efa7aae8c2 remove .DS_Store files (#167) 2026-01-15 14:10:44 -08:00
Jasper Butcher
e94fdf63e7 Add search path for rfd3 configurations (#147)
* Add search path for rfd3 configurations

* Add search path for rfd3 configurations

* Add Hydra searchpath for rf3 and rfd3 model-specific configs (#166)

* Initial plan

* Add search path for rf3 configurations

Co-authored-by: Ubiquinone-dot <66851659+Ubiquinone-dot@users.noreply.github.com>

* Add rfd3 searchpath to validate.yaml and dev.yaml

Co-authored-by: Ubiquinone-dot <66851659+Ubiquinone-dot@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Ubiquinone-dot <66851659+Ubiquinone-dot@users.noreply.github.com>

---------

Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
2026-01-14 16:59:18 -08:00
Rafael Brent
88d212c08d docs: update ppi docs (#159)
docs: update ppi docs to recommend lower-temperature settings

Co-authored-by: Rafi Brent <rafi.brent@gmail.com>
2026-01-08 13:38:25 -08:00
Daan Krol
8bfde2381a feat: Add Intel XPU support for Foundry Models (#156)
feat: Add Intel XPU support for all models

- Add XPU accelerator, precision, and strategy classes
- Update DDP utilities to detect and use Intel XPU
- Add XPU trainer configs for RF3 and RFD3
- Update MPNN inference engine for XPU compatibility
- Update README with XPU documentation
2026-01-07 16:30:04 -08:00
Rachel Clune
73865046c5 Creating the external foundry documentation structure and first round of documentation for RFD3 (#143)
* Starting to put together the foundry and RFD3 external documentation

Set up the foundation for Sphinx to be able to build the external docs, first draft of a ppi_design_tutorial has been completed.

* Add RFdiffusion3 documentation and update toctree

Added initial documentation for RFdiffusion3 under models/rfd3/docs/index.rst and linked it in the main docs toctree. Updated toctree maxdepth for better navigation and added a symlink for the rfd3 model documentation.

* Update and expand RFdiffusion3 documentation

Added introductory and reference documentation files, improved the index structure with general information and examples, and enhanced the PPI design tutorial with additional notes, figures, and clarifications. Also fixed a typo in a PDB filename.

* Update RFD3 documentation and tutorial content

Expanded the Sphinx static path to include RFD3 assets and made minor formatting and clarity improvements in the main and RFD3-specific documentation. The PPI design tutorial was revised for clarity, improved step-by-step instructions, and better separation of setup and execution steps.

* Update RFD3 documentation and tutorials

Added source_suffix to Sphinx conf.py for Markdown support. Updated index.rst to include new documentation sections. Expanded intro_inference_calculations.md with detailed instructions on inference input formats, job configuration, and output files. Improved input.md formatting for appendices and FAQs. Revised ppi_design_tutorial.md for clarity, added details on settings, and expanded explanations for hotspots and batch inference.

* Update RFD3 docs: clarify input specs and file formats

Expanded and clarified the documentation for RFdiffusion3 input specifications, including more detailed explanations of the 'contig' string, input file types, and example YAML/JSON formats. Improved the intro to inference calculations to better explain the structure and usage of settings files, and updated descriptions for job configuration and output files. Added a placeholder for configuration options documentation.

* Update RFdiffusion3 input documentation and examples

Expanded and clarified the documentation for RFdiffusion3 input specification, including detailed explanations of CLI arguments, InputSpecification fields, the InputSelection mini-language, contig string formatting, and advanced options such as partial diffusion and CIF parser arguments. Added more examples, debugging recommendations, and an updated FAQ. Also updated the output file naming explanation for clarity. Removed the obsolete configuration_options.md file.

Note that images are still not being rendered correctly in many of the md files. Fix will be in future commit.

* PPI tutorial and RFD3 docs update

Created output files for PPI tutorial and listed their locations. Made edits to files to add labels to sections to remove sphinx warnings.

* Delete docs/source/conf.py~

This is an auto-save file from emacs - it does not need to be in the repo.

* Delete docs/source/index.rst~

This is an auto-saved copy of index.rst,  it does not need to be in the repo

* Adding missing images and fixing docs symlink

* Fix grammatical error in RFdiffusion3 documentation

Fixed typo, clarified enzyme design language.

* Fix typos and enhance clarity in inference docs

Corrected typos and improved clarity in the documentation regarding inference settings and file formats.
2026-01-02 11:21:10 -08:00
Jasper Butcher
2bfcd663bc Fix skip existing not working (#140) 2025-12-27 19:57:29 +00:00
Jasper Butcher
122f39b7e8 Bugfix to Partial diffusion where partial_t doesn't affect output (#138)
Return noise_schedule instead of t_hat
2025-12-27 12:27:19 +00:00
Jasper Butcher
48c8966345 Improve 'unindex' field description in input_parsing.py (#129)
* Improve 'unindex' field description in input_parsing.py

Updated the description for the 'unindex' field to clarify its purpose and usage.

* Make format
2025-12-23 09:19:48 +00:00
Jasper Butcher
ffa9411a56 Fix symmetry issues (#126)
Addressing #115
2025-12-22 14:59:36 +00:00
Rohith Krishna
a36d29c5c0 Pr/lorenzo tarricone/98 (#125)
* Add tetrahedral, octahedral, and icosahedral symmetry frames and improved chain ID handling

Apply formatting fix and update symmetry contribution

* chore: cleanup and docs addition

chore: ruff

---------

Co-authored-by: LorenzoTarricone <tarricone.lory01.lt@gmail.com>
Co-authored-by: Rohith Krishna <rohith@Rohiths-MacBook-Air.local>
2025-12-20 11:42:25 -08:00
Rohith Krishna
e0d149f6e8 chore: ruff 2025-12-20 10:56:29 -08:00
Rohith Krishna
58e03a1035 fix to cli to enable running from pip installed package, cleanuo 2025-12-19 23:50:38 -08:00
Rohith Krishna
9a3e717978 fix: use relative paths for rf3 config path 2025-12-19 20:10:37 -08:00
Jasper Butcher
e50a652252 Update models/rfd3/src/rfd3/inference/input_parsing.py
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-19 09:25:57 +01:00
jbutch
123ff20eae Make format 2025-12-19 00:24:44 -08:00