Giter VIP home page Giter VIP logo

hyperkohaku's Introduction

Here is KohakuBlueLeaf UwU

Kohaku: A cute dragon girl

BlueLeaf: An undergraduate student in Taiwan

kohakublueleaf

  • ๐Ÿ”ญ Iโ€™m currently working on LyCORIS

  • ๐Ÿค Iโ€™m looking for help with HyperKohaku

  • ๐Ÿ’ฌ Ask me about Python, NN, Web Crawler

  • ๐Ÿ“ซ How to reach me [email protected]

  • โšก Fun fact I never watched Lycoris-Recoil

Connect with me:

kblueleaf blueleaf ZwgFFT4bSy

GitRoll Profile Badge

kohakublueleaf

ย kohakublueleaf

trophy

Sponsorship

Buy Me A Coffee

paypal.me: https://www.paypal.com/paypalme/kblueleaf
BTC: 36VHoCKxgp2u3YWQ8gNMDQR3fT49S5sRtf
ETH: 0x8023c8c0a10a4da4e6746cbd238a8bc990fbba60
LTC: MCpMKubB8eeKPZ6LsfW9A7pJP23YLoLT9T

hyperkohaku's People

Contributors

kohakublueleaf avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

hyperkohaku's Issues

Question about the LiLora aux matrix

I noticed that the original paper stated that down_aux/up_aux is a progressive orthogonal vector, but the code in this repository orthogonalized the auxiliary layer weights with down_dim/out_feature_dim. This may be the reason why losses cannot be converged. Can you take a look at it? Thanks!

safetensors_rust.SafetensorError: Error while deserializing header: HeaderTooLarge

I followed all the steps:

  • I trained pre-optimized loras with train_preoptimized_liloras.py
  • Used them to train the hypernetwork with train_hyperdreambooth.py
  • Passed an image in input to generate the weights with hypernetwork_gen_weigth.py
    At this point, I would like to test what I got running inference_test.py, but I get this error:
Traceback (most recent call last):
  File "/home/wizard/bendai/research/dawnai/hyper_dreambooth/inference_test.py", line 19, in <module>
    pipe.unet.load_attn_procs(model_path)
  File "/home/wizard/mambaforge/envs/hyper/lib/python3.9/site-packages/diffusers/loaders.py", line 297, in load_attn_procs
    state_dict = safetensors.torch.load_file(model_file, device="cpu")
  File "/home/wizard/mambaforge/envs/hyper/lib/python3.9/site-packages/safetensors/torch.py", line 259, in load_file
    with safe_open(filename, framework="pt", device=device) as f:
safetensors_rust.SafetensorError: Error while deserializing header: HeaderTooLarge

Any idea? Thank you!

Loss does not converge during HyperNet training

The loss function converges normally during Pre-Optimize training, but during the subsequent HyperNet training, both the gen_loss and weight_loss do not converge.

after exporting the HyperNet predicted weights to standard LoRA, the inference results are abnormal.

Read Me

Hello, is the project complete and do you plan to add command examples for us to run the codes?
Thanks.

pretrained hypernetwork model

first thank you for progress awesome project !

I want to know about milestone or progress of this project

did you train hyper network model now? or

how many time take to train hyper network model?

Finally, based on the current state, I wonder if the current project is actually usable.

environment problem

Could you provide information on the Torch versions that are compatible with this code?

How to mask the face during training?

Thx for your project!~

I find this sentence in readme: 'Implement better dreambooth training (like masking the face during training)'.

But how to mask the face during training? Eg: random mask 50%?

questions about running requirements

Thank you for this fantastic project.
I have some questions regarding the operational condition. What is the required GPU memory for this project? Does this project support multi-GPU training? How long does it take to achieve reasonably good results with only four 32GB V100?

Pre Optimize problem

I have written a script to export the pre-optimized weights(pre_optimized.bin ) to LoRA according to designated ID , and tested it using inference_test.py, I found that the generated result is distorted. Can I provide my script so that everyone can verify it as well?

Multi GPU parallelization

Hi! Thank you for the amazing work. Training on a single GPU is quite slow, and since the project uses accelerate, I was expecting it to run also on multiple GPUs. However, after some small tweaks (removing the --put_in_cpu flag when training the preoptimized loras, and substituting hypernetwork.train_params() with hypernetwork.module.train_params()) I am stuck with this error:

Traceback (most recent call last):                                                                                                                            
  File "/home/hyper_dreambooth/./train_hyperdreambooth.py", line 1323, in <module>                                              
    main(args)                                                                                                                                                
  File "/home/hyper_dreambooth/./train_hyperdreambooth.py", line 1117, in main                                                  
    pred_weights = hypernetwork(pixel_values)                                                                                                                 
  File "/home/mambaforge/envs/hyper/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl                                  
    return forward_call(*args, **kwargs)                                                                                                                      
  File "/home/mambaforge/envs/hyper/lib/python3.9/site-packages/torch/nn/parallel/distributed.py", line 1139, in forward                               
    if torch.is_grad_enabled() and self.reducer._rebuild_buckets():                                                                                           
RuntimeError: Expected to have finished reduction in the prior iteration before starting a new one. This error indicates that your module has parameters that 
were not used in producing loss. You can enable unused parameter detection by passing the keyword argument `find_unused_parameters=True` to `torch.nn.parallel
.DistributedDataParallel`, and by                                                                                                                             
making sure all `forward` function outputs participate in calculating loss.                                                                                   
If you already have done the above, then the distributed data parallel module wasn't able to locate the output tensors in the return value of your module's `f
orward` function. Please include the loss function and the structure of the return value of `forward` of your module when reporting this issue (e.g. list, dic
t, iterable).                                                                                                                                                 
Parameter indices which did not receive grad for rank 3: 1                                                                                                    
 In addition, you can set the environment variable TORCH_DISTRIBUTED_DEBUG to either INFO or DETAIL to print out information about which particular parameters
 did not receive gradient on this rank as part of this error  

Am I doing something wrong, or is the code intended to run only on a single GPU?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.