This commit is contained in:
leejet 2024-07-28 15:39:10 +08:00
parent 984a7724d9
commit cce01e9532
2 changed files with 4 additions and 4 deletions

View File

@ -4,7 +4,7 @@
#include "mmdit.hpp" #include "mmdit.hpp"
#include "unet.hpp" #include "unet.hpp"
struct DiffuisionModel { struct DiffusionModel {
virtual void compute(int n_threads, virtual void compute(int n_threads,
struct ggml_tensor* x, struct ggml_tensor* x,
struct ggml_tensor* timesteps, struct ggml_tensor* timesteps,
@ -24,7 +24,7 @@ struct DiffuisionModel {
virtual int64_t get_adm_in_channels() = 0; virtual int64_t get_adm_in_channels() = 0;
}; };
struct UNetModel : public DiffuisionModel { struct UNetModel : public DiffusionModel {
UNetModelRunner unet; UNetModelRunner unet;
UNetModel(ggml_backend_t backend, UNetModel(ggml_backend_t backend,
@ -72,7 +72,7 @@ struct UNetModel : public DiffuisionModel {
} }
}; };
struct MMDiTModel : public DiffuisionModel { struct MMDiTModel : public DiffusionModel {
MMDiTRunner mmdit; MMDiTRunner mmdit;
MMDiTModel(ggml_backend_t backend, MMDiTModel(ggml_backend_t backend,

View File

@ -79,7 +79,7 @@ public:
std::shared_ptr<Conditioner> cond_stage_model; std::shared_ptr<Conditioner> cond_stage_model;
std::shared_ptr<FrozenCLIPVisionEmbedder> clip_vision; // for svd std::shared_ptr<FrozenCLIPVisionEmbedder> clip_vision; // for svd
std::shared_ptr<DiffuisionModel> diffusion_model; std::shared_ptr<DiffusionModel> diffusion_model;
std::shared_ptr<AutoEncoderKL> first_stage_model; std::shared_ptr<AutoEncoderKL> first_stage_model;
std::shared_ptr<TinyAutoEncoder> tae_first_stage; std::shared_ptr<TinyAutoEncoder> tae_first_stage;
std::shared_ptr<ControlNet> control_net; std::shared_ptr<ControlNet> control_net;