fi_model.golden_run() produces different outputs than the original unwrapped model, causing incorrect observer metrics (RMSE, MAE, EqualRate) and baseline measurements.
To reproduce the issue:
import torch
from torchvision.models import vgg11, VGG11_Weights
from mrfi import MRFI, EasyConfig
model = vgg11(weights=VGG11_Weights.DEFAULT).eval()
x = torch.randn(1, 3, 224, 224)
# Original model output
y_original = model(x)
# MRFI golden run output
fi_model = MRFI(model, EasyConfig.load_preset('default_fi'))
with fi_model.golden_run():
y_golden = fi_model(x)
# They should be identical but aren't
print(torch.abs(y_original - y_golden).max()) # Non-zero!
golden_run() disables fault injection but leaves model hooks active, intercepting and processing data.