mirror of
https://github.com/leejet/stable-diffusion.cpp.git
synced 2026-07-30 06:40:41 -05:00
feat: add Anima support (#1296)
This commit is contained in:
@@ -1094,6 +1094,14 @@ std::string convert_tensor_name(std::string name, SDVersion version) {
|
||||
}
|
||||
}
|
||||
|
||||
if (is_lora && sd_version_is_anima(version)) {
|
||||
static const std::string anima_diffusion_prefix = "model.diffusion_model.";
|
||||
static const std::string anima_net_prefix = "model.diffusion_model.net.";
|
||||
if (starts_with(name, anima_diffusion_prefix) && !starts_with(name, anima_net_prefix)) {
|
||||
name = anima_net_prefix + name.substr(anima_diffusion_prefix.size());
|
||||
}
|
||||
}
|
||||
|
||||
// cond_stage_model
|
||||
{
|
||||
for (const auto& prefix : cond_stage_model_prefix_vec) {
|
||||
|
||||
Reference in New Issue
Block a user