当前位置: 首页 > article >正文

vscode accelerate deepspeed配置

accelerate训练

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Current File",
            "type": "python",
            "request": "launch",
            // "program": "${file}",
            "module": "accelerate.commands.launch",
            "console": "integratedTerminal",
            "env": {
                "CUDA_VISIBLE_DEVICES": "4,5,6,7"  // 与
            },
            "args": [
                 train sdxl lora
                "--num_processes=4",
                "examples/text_to_image/train_text_to_image_lora_sdxl.py",
                "--dataset_name","lambdalabs/naruto-blip-captions",
                "--output_dir","exp",
                "--resolution","1024", "--random_flip",
                "--train_batch_size","1",
                "--num_train_epochs","2", "--checkpointing_steps","500",
                "--learning_rate","1e-04", "--lr_scheduler","constant", "--lr_warmup_steps","0",
                "--mixed_precision","fp16",
                "--seed","42",
                "--output_dir","sd-naruto-model-lora-sdxl",
                "--validation_prompt","cute dragon creature",
            ]   
        }
    ]
}

accelerate+deepspeed训练

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Current File",
            "type": "python",
            "request": "launch",
            // "program": "${file}",
            "module": "accelerate.commands.launch",
            "console": "integratedTerminal",
            "env": {
                "CUDA_VISIBLE_DEVICES": "4,5,6,7"
            },
            "args": [
                 train sdxl lora
                "--config_file","my/deepspeed_config/default_config.yaml",  //跟上面只有这个区别
                "--num_processes=4",
                "examples/text_to_image/train_text_to_image_lora_sdxl.py",
                "--dataset_name","lambdalabs/naruto-blip-captions",
                "--output_dir","exp",
                "--resolution","1024", "--random_flip",
                "--train_batch_size","1",
                "--num_train_epochs","2", "--checkpointing_steps","500",
                "--learning_rate","1e-04", "--lr_scheduler","constant", "--lr_warmup_steps","0",
                "--mixed_precision","fp16",
                "--seed","42",
                "--output_dir","sd-naruto-model-lora-sdxl",
                "--validation_prompt","cute dragon creature",
            ]   
        }
    ]
}

http://www.kler.cn/a/507472.html

相关文章:

  • qml LevelAdjust详解
  • 【后端面试总结】tls中.crt和.key的关系
  • Ansible自动化运维:基础与实践
  • 《C++11》深入剖析正则表达式库:解锁文本处理的高效之道
  • C#与Vue2上传下载Excel文件
  • 一体机cell服务器更换内存步骤
  • 强推未发表!3D图!Transformer-LSTM+NSGAII工艺参数优化、工程设计优化!
  • 人脸识别SDK(Android)之项目回顾总结
  • 【Ubuntu】如何设置 GRUB 启动器的用户名和密码
  • Unix 与 Linux:操作系统的核心区别
  • 【2024年华为OD机试】(B卷,100分)- 恢复数字序列 (Java JS PythonC/C++)
  • PE文件:节表-添加节
  • 记一次数据库连接 bug
  • RabbitMQ介绍以及基本使用
  • Python从0到100(八十四):神经网络-卷积神经网络训练CIFAR-10数据集
  • 反转字符串中的单词 II:Swift 实现与详解
  • Qt之登录界面(splash)
  • PCL 计算点云的均值与标准差【2025最新版】
  • ASP.Net Identity + IODC 解析ReturnUrl
  • 【无线感知会议系列-21 】无线感知6G 研究愿景
  • 电气工程中的计算智能
  • Springboot(五十八)SpringBoot3使用Redisson实现接口的限流功能
  • .Net Core微服务入门全纪录(二)——Consul-服务注册与发现(上)
  • Spring boot学习文档
  • Linux 内核自旋锁spinlock(一)
  • 基于单片机的智能火灾报警系统设计