Skip to content

Conversation

@yiyixuxu
Copy link
Collaborator

@yiyixuxu yiyixuxu commented Jan 22, 2026

add two more test:

  1. test loading from standard non-modular repo
  2. test running inference in modular setting: run text_encoder, vae_encoder/vae_decoder standalone
  3. added required_inputs signature tests: e.g prompt should be a required input for most pipelines

@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@yiyixuxu
Copy link
Collaborator Author

yiyixuxu commented Feb 5, 2026

will need to adjust conflicts and fix more stuff after this #13078 and #13063
but ready for a review now! @DN6 @sayakpaul

feel free to push directly into this PR too if you see anything you want to change

@yiyixuxu yiyixuxu requested review from DN6 and sayakpaul February 5, 2026 08:54
Copy link
Member

@sayakpaul sayakpaul left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great test!

Comment on lines +144 to +146
def test_loading_from_default_repo(self):
if self.default_repo_id is None:
return
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
def test_loading_from_default_repo(self):
if self.default_repo_id is None:
return
def test_loading_from_default_repo(self):
if self.default_repo_id is None:
pytest.mark.skip("The underlying test class doesn't implement `default_repo_id`, skipping test.")

Comment on lines +170 to +171
# a hack to workaround the fact the default pipeline properties are often incorrect for testing cases,
# #e.g. vae_scale_factor is ususally not 8 because vae is configured to be smaller for testing
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this something because of how defaults are set? I think we should fix this.

decode_inputs = filter_inputs(decode_available, decoder_node.blocks.input_names)
modular_output = decoder_node(**decode_inputs).images

assert modular_output.shape == standard_output.shape, (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we also add a check for the outputs? The outputs should also match right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants