question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Reproducing Figure 11 and reporting success rate

See original GitHub issue

Hi all and @avnishn,

I’ve been trying to reproduce results from Figure 11 in https://arxiv.org/pdf/1910.10897.pdf using https://github.com/rlworkgroup/garage/blob/08492007d6e2d9ead9beb83a8a4247e52019ac7d/metaworld_examples/sac_metaworld.py and hyper-parameters reported in Table 3. Should I use Table 3 for hyper-parameters?

One thing which is not clear to me is how the success rate is reported. I notice the env.step returns ‘success’ but want to verify here that is what reported in the paper. Here is the code the I use to report results ( random action is used for simplicity):

from metaworld.envs import ALL_V2_ENVIRONMENTS_GOAL_OBSERVABLE
env_cls = ALL_V2_ENVIRONMENTS_GOAL_OBSERVABLE['hammer-v2-goal-observable']
eval_env= env_cls(seed=0)
eval_env.seed(0)
avg_reward = 0 
success_rate = 0 
num_evals = 2

for _ in range(num_evals):
    obs = eval_env.reset()
    done = False
    stp = 0
    while not done and stp < eval_env.max_path_length:
        obs, reward, done, info = eval_env.step(eval_env.action_space.sample())
        avg_reward += reward
        stp += 1
        if 'success' in info:
            success_rate += info['success']
avg_reward /= num_evals
success_rate /= num_evals

Is this the right way to report the success rate like Figure 11? Thanks for your help. Rasool

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
avnishncommented, Jan 12, 2022
  1. whoops sorry, I edited my answer. Gave you the wrong answer the first time.
  2. yes, and they should be the same as the hparams in the launcher that you linked. 3)yes.
0reactions
krzentnercommented, Jan 23, 2022

To be clear, since the above conversation was unclear to me: In MetaWorld, an episode is considered successful if the info['success'] ever becomes 1.0 during that episode. SuccessRate therefore needs to be computed across many episodes to be meaningful.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Reporting of Pregnancy Success Rates From Assisted ...
FCSRCA requires that each assisted reproductive technology (ART) program annually report pregnancy success rates achieved by such ART ...
Read more >
Reporting assisted reproductive technology success rates on ...
Thirty-seven fig- ures reported success rates 'per embryo transfer', two figures used 'per egg collec- tion', and no figures described success ...
Read more >
Archived ART Reports and Spreadsheets - CDC
ART Success Rates Reports have been published annually since 1997. They provide an in-depth picture of the type, number, and outcome of ART...
Read more >
Early Pregnancy Loss - ACOG
The largest U.S. trial reported that success rates after medical management of anembryonic gestations (81%) was lower than with embryonic or fetal death...
Read more >
Infertility and In Vitro Fertilization - WebMD
You will then be tested to determine whether you're ready for egg ... The CDC reports that the success rate of IVF is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found