# Learning to stop while learning to predict

## Motivation

* Task-imbalanced meta learning: different tasks need different numbers of gradient steps for adaptation&#x20;
* Deep learning based algorithms usually have a fixed number of iterations in the architecture.

could we learn to stop automatically?

## Overview

![](https://1687130946-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MEnQbUIupyAn8eMmrmG%2F-MIHiQuft0XG6NDwt6lW%2F-MIHn7TXAJZfUu2vMRR1%2Ff11.jpg?alt=media\&token=4035c9b5-c55e-4606-9819-f014bfcb5f29)

* predictive model $$\mathcal{F}\_\theta$$ : transforms the input x to generate a path of states $$x\_1, x\_2, ...,x\_T$$&#x20;
* stop policy $$\pi\_\phi$$ : sequentially observes the states $$x\_t$$ and determines the probability of stop at layer $$t$$&#x20;
* variational stop time distribution $$q\_\phi$$ : stop time distribution induced by stopping policy $$\pi\_\phi$$&#x20;

![](https://1687130946-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MEnQbUIupyAn8eMmrmG%2F-MIHoeSYZ4UY9jXgVaex%2F-MII4beOqxNSI_036r-M%2FLearn%20To%20Stop%20While%20To%20Predict-02.jpg?alt=media\&token=bbf96551-1596-4115-b0f7-1c95872f920c)

![](https://1687130946-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MEnQbUIupyAn8eMmrmG%2F-MIHoeSYZ4UY9jXgVaex%2F-MII4etkJerQx9ot0qbV%2FLearn%20To%20Stop%20While%20To%20Predict-03.jpg?alt=media\&token=b18f6b20-aabc-4557-a41c-29d72284629c)

## Reference

* <https://icml.cc/Conferences/2020/ScheduleMultitrack?event=6279>
* <https://icml.cc/media/Slides/icml/2020/virtual(no-parent)-14-17-00UTC-6279-learning_to_sto.pdf>
* <https://www.youtube.com/watch?v=3VqzhP44Eic>
