File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
tests/backend/patches/lora_conversions Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change 1
- import unittest .mock
2
1
import pytest
3
2
import torch
4
- import unittest
3
+ from unittest import mock
5
4
6
5
7
6
from invokeai .backend .patches .layers .utils import swap_shift_scale_for_linear_weight
@@ -140,7 +139,7 @@ def test_adaLN_should_be_approximated_if_present_while_converting():
140
139
adaLN_layer_key = 'final_layer.adaLN_modulation.1'
141
140
prefixed_layer_key = FLUX_LORA_TRANSFORMER_PREFIX + adaLN_layer_key
142
141
143
- with unittest . mock .patch (
142
+ with mock .patch (
144
143
'invokeai.backend.patches.lora_conversions.flux_diffusers_lora_conversion_utils.approximate_flux_adaLN_lora_layer_from_diffusers_state_dict'
145
144
) as mock_approximate_func :
146
145
model = lora_model_from_flux_diffusers_state_dict (state_dict , alpha = 8.0 )
You can’t perform that action at this time.
0 commit comments