Run this model with HF Jobs
Run Salesforce/FOFPred on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/Salesforce/FOFPred. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/Salesforce/FOFPred on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use Salesforce/FOFPred with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use Salesforce/FOFPred with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("Salesforce/FOFPred", dtype=torch.bfloat16, device_map="cuda") prompt = "Turn this cat into a dog" input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png") image = pipe(image=input_image, prompt=prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Improve model card: add paper link, project page, and update metadata
Browse filesHi! I'm Niels from the community science team at Hugging Face.
I've opened this PR to improve the model card for **FOFPred**. Specifically:
- Linked the model to the paper: [Future Optical Flow Prediction Improves Robot Control & Video Generation](https://huggingface.co/papers/2601.10781).
- Added a link to the project page and the GitHub repository.
- Updated the `pipeline_tag` to `image-to-video` as the model generates a sequence of flow frames.
- Added a BibTeX citation for the work.
Please review and merge this if it looks good!
12345672 unmodified lines1011121314151635 unmodified lines5253545556575859606162633 unmodified lines67686970---license: apache-2.0library_name: diffuserspipeline_tag: image-to-imagetags:- optical-flow prediction- motion prediction2 unmodified lines# FOFPred: Language-Driven Future Optical Flow Prediction**FOFPred** is a diffusion-based model that predicts future optical flow from a single image guided by natural language instructions. Given an input image and a text prompt describing a desired action (e.g., *"Moving the water bottle from right to left"*), FOFPred generates 4 sequential optical flow frames showing how objects would move.## Usage35 unmodified lines## Architecture| Component | Model ||-----------|-------|| **V-LLM** | Qwen2.5-VL-3B-Instruct || **DiT** | OmniGen2Transformer3DModel || **VAE** | FLUX.1-dev AutoencoderKL || **Scheduler** | FlowMatchEulerDiscreteScheduler |## Acknowledgements3 unmodified lines## LicenseOur code and weights are released under the [CC by-NC 4.0 license](https://creativecommons.org/licenses/by-nc/4.0/deed.en).12345672 unmodified lines10111213141516171835 unmodified lines54555657585960616263646566676869707172737475763 unmodified lines80818283---library_name: diffuserslicense: apache-2.0pipeline_tag: image-to-videotags:- optical-flow prediction- motion prediction2 unmodified lines# FOFPred: Language-Driven Future Optical Flow Prediction**FOFPred** is a diffusion-based model that predicts future optical flow from a single image guided by natural language instructions. Given an input image and a text prompt describing a desired action (e.g., *"Moving the water bottle from right to left"*), FOFPred generates 4 sequential optical flow frames showing how objects would move to accomplish that action.[Paper](https://huggingface.co/papers/2601.10781) | [Project Page](https://fofpred.github.io) | [GitHub](https://github.com/SalesforceAIResearch/FOFPred)## Usage35 unmodified lines## Architecture| Component | Model | Description ||-----------|-------|-------------|| **V-LLM** | Qwen2.5-VL-3B-Instruct | Multimodal understanding of images and text || **DiT** | OmniGen2Transformer3DModel | Modification of OmniGen2Transformer to generate frame sequences || **VAE** | FLUX.1-dev AutoencoderKL | VAE (AutoencoderKL model) || **Scheduler** | FlowMatchEulerDiscreteScheduler | Efficient flow-matching sampler |## Citation```bibtex@article{ranasinghe2025future,title={Future Optical Flow Prediction Improves Robot Control & Video Generation},author={Ranasinghe, Kanchana and Zhou, Honglu and Fang, Yu and Yang, Luyu and Xue, Le and Xu, Ran and Xiong, Caiming and Savarese, Silvio and Ryoo, Michael S and Niebles, Juan Carlos},journal={arXiv preprint arXiv:2601.10781},year={2025}}```## Acknowledgements3 unmodified lines## LicenseThe code and weights in this repository are released under the [Apache License 2.0](https://github.com/SalesforceAIResearch/FOFPred/blob/main/LICENSE.txt). (Note: Some documentation may refer to CC BY-NC 4.0).
README.md+23-10