<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: dlimeng</title>
    <description>The latest articles on DEV Community by dlimeng (@dlimeng).</description>
    <link>https://dev.to/dlimeng</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1133650%2F612d7112-eb6b-47ff-9a6c-ea5511c41974.jpeg</url>
      <title>DEV Community: dlimeng</title>
      <link>https://dev.to/dlimeng</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/dlimeng"/>
    <language>en</language>
    <item>
      <title>AI绘画中UNet用于预测噪声</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Mon, 18 Dec 2023 07:30:29 +0000</pubDate>
      <link>https://dev.to/dlimeng/aihui-hua-zhong-unetyong-yu-yu-ce-zao-sheng-4ngk</link>
      <guid>https://dev.to/dlimeng/aihui-hua-zhong-unetyong-yu-yu-ce-zao-sheng-4ngk</guid>
      <description>&lt;h2&gt;
  
  
  介绍
&lt;/h2&gt;

&lt;p&gt;在AI绘画领域中，UNet是一种常见的神经网络架构，广泛用于图像相关的任务，尤其是在图像分割领域中表现突出。UNet最初是为了解决医学图像分割问题而设计的，但其应用已经扩展到了多种图像处理任务。&lt;/p&gt;

&lt;h2&gt;
  
  
  特点
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;对称结构：UNet的结构呈现为“U”形，分为收缩路径（下采样）和扩展路径（上采样）两部分，因此得名UNet。这种结构有助于网络在保持上下文信息的同时捕获精细的细节。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;跳跃连接（Skip Connections）：UNet通过在下采样和上采样路径之间建立跳跃连接，能够在网络的深层保留高分辨率特征。这对于精确地定位和分割图像中的对象至关重要。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;灵活性：尽管最初是为医学图像设计的，UNet的结构被证明对于各种图像分割任务都非常有效，包括但不限于卫星图像分析、地理信息系统（GIS）应用等。&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  架构
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--dGNuWMOf--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9mten18x2xaxecjzae7p.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--dGNuWMOf--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9mten18x2xaxecjzae7p.png" alt="Image description" width="800" height="72"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;这张图片展示了UNet架构的典型布局。UNet由两部分组成：收缩路径（下采样）和扩展路径（上采样），中间通过跳跃连接相连。&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;收缩路径：由蓝色箭头表示，它通过连续的卷积层（conv 3x3）和ReLU激活函数处理输入图像，然后应用最大池化（max pool 2x2，红色箭头向下）来降低分辨率并增加特征图的深度。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;扩展路径：由绿色箭头表示，它通过上采样卷积（up-conv 2x2）将特征图分辨率增加，并通过跳跃连接（灰色箭头），将收缩路径中相应尺寸的特征图与上采样后的特征图合并。合并后，再次应用卷积层（conv 3x3）和ReLU激活函数。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;跳跃连接：它们是图中的灰色箭头，将收缩路径的特征图直接传输到扩展路径的相应层，这有助于在上采样时恢复图像的细节。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;输出：最后，一个1x1的卷积层（conv 1x1，蓝色箭头指向输出）将深层特征图转换为所需的输出分割图（在这里是输出分割地图）。&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;整个UNet架构是一个对称结构，它允许网络在分割任务中同时学习图像的局部特征（通过下采样）和全局上下文（通过上采样和跳跃连接）。这种结构使得UNet在医学图像分割和其他需要精确定位的图像处理任务中非常有效。&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s---ghQSbmd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xxvgxdq5bz6n29zxh8xy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s---ghQSbmd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xxvgxdq5bz6n29zxh8xy.png" alt="Image description" width="800" height="541"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  数学公式
&lt;/h2&gt;

&lt;p&gt;在数学层面上，UNet的操作可以通过卷积（Conv）和池化（Pool）运算来表达，但详细的数学表达会涉及到卷积运算的具体公式，激活函数的选择等，这些通常在具体的研究论文或技术文档中详细描述。&lt;/p&gt;

&lt;p&gt;为了简化，可以认为每一步的操作是一个函数 ( f )，它接受一个输入 ( x ) 并产生一个输出 ( y )，如 ( y = f(x) )。在UNet中，这些函数会是卷积、激活、池化或上采样操作。&lt;/p&gt;

&lt;h2&gt;
  
  
  代码实现
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import torch
import torch.nn as nn
import torch.nn.functional as F

class DoubleConv(nn.Module):
    """(卷积 =&amp;gt; [BN] =&amp;gt; ReLU) * 2"""

    def __init__(self, in_channels, out_channels, mid_channels=None):
        super().__init__()
        if not mid_channels:
            mid_channels = out_channels
        self.double_conv = nn.Sequential(
            nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1),
            nn.BatchNorm2d(mid_channels),
            nn.ReLU(inplace=True),
            nn.Conv2d(mid_channels, out_channels, kernel_size=3, padding=1),
            nn.BatchNorm2d(out_channels),
            nn.ReLU(inplace=True)
        )

    def forward(self, x):
        return self.double_conv(x)

class UNet(nn.Module):
    def __init__(self, n_channels, n_classes):
        super(UNet, self).__init__()
        self.n_channels = n_channels
        self.n_classes = n_classes

        # UNet的下采样部分
        self.inc = DoubleConv(n_channels, 64)
        self.down1 = DoubleConv(64, 128)
        self.down2 = DoubleConv(128, 256)
        self.down3 = DoubleConv(256, 512)
        self.down4 = DoubleConv(512, 1024)

        # UNet的上采样部分
        self.up1 = nn.ConvTranspose2d(1024, 512, kernel_size=2, stride=2)
        self.conv1 = DoubleConv(1024, 512)
        self.up2 = nn.ConvTranspose2d(512, 256, kernel_size=2, stride=2)
        self.conv2 = DoubleConv(512, 256)
        self.up3 = nn.ConvTranspose2d(256, 128, kernel_size=2, stride=2)
        self.conv3 = DoubleConv(256, 128)
        self.up4 = nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2)
        self.conv4 = DoubleConv(128, 64)

        # 最后一层卷积，将特征图转换为输出类别
        self.outc = nn.Conv2d(64, n_classes, kernel_size=1)

    def forward(self, x):
        # 向前传播，按顺序应用下采样和上采样
        x1 = self.inc(x)
        x2 = self.down1(x1)
        x3 = self.down2(x2)
        x4 = self.down3(x3)
        x5 = self.down4(x4)
        x = self.up1(x5)
        x = torch.cat([x, x4], dim=1)
        x = self.conv1(x)
        x = self.up2(x)
        x = torch.cat([x, x3], dim=1)
        x = self.conv2(x)
        x = self.up3(x)
        x = torch.cat([x, x2], dim=1)
        x = self.conv3(x)
        x = self.up4(x)
        x = torch.cat([x, x1], dim=1)
        x = self.conv4(x)
        logits = self.outc(x)
        return logits

# 实例化模型，输入通道数为1，输出类别数为2
model = UNet(n_channels=1, n_classes=2)

# 创建一个假的输入数据，其形状为(batch_size, channels, height, width)
input = torch.randn(1, 1, 572, 572)

# 得到模型输出
output = model(input)
print(output.shape)  # 打印输出张量的形状

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;在这个实现中，我们定义了一个DoubleConv模块来执行两次卷积操作，每次卷积后都会执行批量归一化（BatchNorm）和ReLU激活函数。在UNet模型中，我们首先定义了下采样（编码器）和上采样（解码器）的步骤。在上采样步骤中，我们使用转置卷积进行特征图的扩大，并使用torch.cat函数来实现跳跃连接，将编码器的特征与解码器的特征结合起。&lt;/p&gt;

&lt;h2&gt;
  
  
  AI绘画中UNet 与扩散模型结合
&lt;/h2&gt;

&lt;p&gt;UNet架构与扩散模型的结合是在人工智能绘画和图像生成领域的一个相对较新的研究方向。扩散模型，特别是深度学习中的生成扩散模型，已经被证明在生成高质量的图像方面表现出色。它们通过逐步添加噪声到数据中，然后学习如何逆转这个过程来生成数据。&lt;/p&gt;

&lt;p&gt;结合UNet与扩散模型通常涉及以下步骤：&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;特征提取&lt;/strong&gt;：使用UNet的下采样路径来提取输入图像的特征。这些特征捕获了图像的重要信息和上下文。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;特征扩散&lt;/strong&gt;：将这些特征传递给扩散模型，扩散模型将通过添加和学习逆转噪声的过程来扩散特征。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;特征重建&lt;/strong&gt;：使用UNet的上采样路径和跳跃连接来重建和细化特征，这一步骤通常会生成更加精细和清晰的图像。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;图像生成&lt;/strong&gt;：最后，使用1x1卷积或其他类型的映射来将重建的特征转换为最终的图像输出。&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;在这种结合中，UNet通常用于其强大的特征提取和重建能力，而扩散模型用于生成过程中的细节增强和变化模拟。这种结合可以用于创造性绘画、图像修复、风格迁移等任务，其中不仅需要精确的图像内容，还需要高质量的图像纹理和细节。这种方法的一个例子是将扩散模型用于生成纹理，然后通过UNet进行细化，以实现更高质量的图像输出。&lt;/p&gt;

&lt;h2&gt;
  
  
  UNet 应用
&lt;/h2&gt;

&lt;p&gt;UNet架构最初是为医学图像分割而设计的，但由于其高效的特征学习和上下文整合能力，它已经被广泛应用于多种不同的图像处理任务。下面列出了一些UNet的主要应用领域：&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;医学图像分割&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;细胞计数。&lt;/li&gt;
&lt;li&gt;器官定位。&lt;/li&gt;
&lt;li&gt;肿瘤检测。&lt;/li&gt;
&lt;li&gt;病变分割。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;卫星图像处理&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;地物分类。&lt;/li&gt;
&lt;li&gt;道路提取。&lt;/li&gt;
&lt;li&gt;土地覆盖变化检测。&lt;/li&gt;
&lt;li&gt;建筑物检测。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;自然图像分割&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;物体轮廓提取。&lt;/li&gt;
&lt;li&gt;图像背景去除。&lt;/li&gt;
&lt;li&gt;交互式图像编辑。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;农业&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;植物病害检测。&lt;/li&gt;
&lt;li&gt;作物分析。&lt;/li&gt;
&lt;li&gt;农田监测。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;自动驾驶汽车&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;道路和行人检测。&lt;/li&gt;
&lt;li&gt;车辆周边环境的理解。&lt;/li&gt;
&lt;li&gt;交通标志识别。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;工业应用&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;缺陷检测。&lt;/li&gt;
&lt;li&gt;产品质量评估。&lt;/li&gt;
&lt;li&gt;自动化检视系统。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;视频处理&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;运动分析。&lt;/li&gt;
&lt;li&gt;物体追踪。&lt;/li&gt;
&lt;li&gt;视频分割。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;艺术创作&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;风格迁移。&lt;/li&gt;
&lt;li&gt;图像合成。&lt;/li&gt;
&lt;li&gt;动漫角色生成。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;UNet的这些应用通常依赖于其能力来理解图像中的复杂结构，并且能够在分割任务中保留重要的细节信息。它的成功部分归因于其独特的架构，该架构通过跳跃连接将低级别的细节特征与高级别的上下文特征相结合，从而在图像的不同分辨率级别上实现了准确的分割。&lt;/p&gt;

</description>
      <category>ai</category>
      <category>chagpt</category>
    </item>
    <item>
      <title>AI绘画中UNet用于预测噪声</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Mon, 18 Dec 2023 07:29:57 +0000</pubDate>
      <link>https://dev.to/dlimeng/aihui-hua-zhong-unetyong-yu-yu-ce-zao-sheng-1890</link>
      <guid>https://dev.to/dlimeng/aihui-hua-zhong-unetyong-yu-yu-ce-zao-sheng-1890</guid>
      <description>&lt;h2&gt;
  
  
  介绍
&lt;/h2&gt;

&lt;p&gt;在AI绘画领域中，UNet是一种常见的神经网络架构，广泛用于图像相关的任务，尤其是在图像分割领域中表现突出。UNet最初是为了解决医学图像分割问题而设计的，但其应用已经扩展到了多种图像处理任务。&lt;/p&gt;

&lt;h2&gt;
  
  
  特点
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;对称结构：UNet的结构呈现为“U”形，分为收缩路径（下采样）和扩展路径（上采样）两部分，因此得名UNet。这种结构有助于网络在保持上下文信息的同时捕获精细的细节。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;跳跃连接（Skip Connections）：UNet通过在下采样和上采样路径之间建立跳跃连接，能够在网络的深层保留高分辨率特征。这对于精确地定位和分割图像中的对象至关重要。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;灵活性：尽管最初是为医学图像设计的，UNet的结构被证明对于各种图像分割任务都非常有效，包括但不限于卫星图像分析、地理信息系统（GIS）应用等。&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  架构
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--dGNuWMOf--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9mten18x2xaxecjzae7p.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--dGNuWMOf--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9mten18x2xaxecjzae7p.png" alt="Image description" width="800" height="72"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;这张图片展示了UNet架构的典型布局。UNet由两部分组成：收缩路径（下采样）和扩展路径（上采样），中间通过跳跃连接相连。&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;收缩路径：由蓝色箭头表示，它通过连续的卷积层（conv 3x3）和ReLU激活函数处理输入图像，然后应用最大池化（max pool 2x2，红色箭头向下）来降低分辨率并增加特征图的深度。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;扩展路径：由绿色箭头表示，它通过上采样卷积（up-conv 2x2）将特征图分辨率增加，并通过跳跃连接（灰色箭头），将收缩路径中相应尺寸的特征图与上采样后的特征图合并。合并后，再次应用卷积层（conv 3x3）和ReLU激活函数。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;跳跃连接：它们是图中的灰色箭头，将收缩路径的特征图直接传输到扩展路径的相应层，这有助于在上采样时恢复图像的细节。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;输出：最后，一个1x1的卷积层（conv 1x1，蓝色箭头指向输出）将深层特征图转换为所需的输出分割图（在这里是输出分割地图）。&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;整个UNet架构是一个对称结构，它允许网络在分割任务中同时学习图像的局部特征（通过下采样）和全局上下文（通过上采样和跳跃连接）。这种结构使得UNet在医学图像分割和其他需要精确定位的图像处理任务中非常有效。&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s---ghQSbmd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xxvgxdq5bz6n29zxh8xy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s---ghQSbmd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xxvgxdq5bz6n29zxh8xy.png" alt="Image description" width="800" height="541"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  数学公式
&lt;/h2&gt;

&lt;p&gt;在数学层面上，UNet的操作可以通过卷积（Conv）和池化（Pool）运算来表达，但详细的数学表达会涉及到卷积运算的具体公式，激活函数的选择等，这些通常在具体的研究论文或技术文档中详细描述。&lt;/p&gt;

&lt;p&gt;为了简化，可以认为每一步的操作是一个函数 ( f )，它接受一个输入 ( x ) 并产生一个输出 ( y )，如 ( y = f(x) )。在UNet中，这些函数会是卷积、激活、池化或上采样操作。&lt;/p&gt;

&lt;h2&gt;
  
  
  代码实现
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import torch
import torch.nn as nn
import torch.nn.functional as F

class DoubleConv(nn.Module):
    """(卷积 =&amp;gt; [BN] =&amp;gt; ReLU) * 2"""

    def __init__(self, in_channels, out_channels, mid_channels=None):
        super().__init__()
        if not mid_channels:
            mid_channels = out_channels
        self.double_conv = nn.Sequential(
            nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1),
            nn.BatchNorm2d(mid_channels),
            nn.ReLU(inplace=True),
            nn.Conv2d(mid_channels, out_channels, kernel_size=3, padding=1),
            nn.BatchNorm2d(out_channels),
            nn.ReLU(inplace=True)
        )

    def forward(self, x):
        return self.double_conv(x)

class UNet(nn.Module):
    def __init__(self, n_channels, n_classes):
        super(UNet, self).__init__()
        self.n_channels = n_channels
        self.n_classes = n_classes

        # UNet的下采样部分
        self.inc = DoubleConv(n_channels, 64)
        self.down1 = DoubleConv(64, 128)
        self.down2 = DoubleConv(128, 256)
        self.down3 = DoubleConv(256, 512)
        self.down4 = DoubleConv(512, 1024)

        # UNet的上采样部分
        self.up1 = nn.ConvTranspose2d(1024, 512, kernel_size=2, stride=2)
        self.conv1 = DoubleConv(1024, 512)
        self.up2 = nn.ConvTranspose2d(512, 256, kernel_size=2, stride=2)
        self.conv2 = DoubleConv(512, 256)
        self.up3 = nn.ConvTranspose2d(256, 128, kernel_size=2, stride=2)
        self.conv3 = DoubleConv(256, 128)
        self.up4 = nn.ConvTranspose2d(128, 64, kernel_size=2, stride=2)
        self.conv4 = DoubleConv(128, 64)

        # 最后一层卷积，将特征图转换为输出类别
        self.outc = nn.Conv2d(64, n_classes, kernel_size=1)

    def forward(self, x):
        # 向前传播，按顺序应用下采样和上采样
        x1 = self.inc(x)
        x2 = self.down1(x1)
        x3 = self.down2(x2)
        x4 = self.down3(x3)
        x5 = self.down4(x4)
        x = self.up1(x5)
        x = torch.cat([x, x4], dim=1)
        x = self.conv1(x)
        x = self.up2(x)
        x = torch.cat([x, x3], dim=1)
        x = self.conv2(x)
        x = self.up3(x)
        x = torch.cat([x, x2], dim=1)
        x = self.conv3(x)
        x = self.up4(x)
        x = torch.cat([x, x1], dim=1)
        x = self.conv4(x)
        logits = self.outc(x)
        return logits

# 实例化模型，输入通道数为1，输出类别数为2
model = UNet(n_channels=1, n_classes=2)

# 创建一个假的输入数据，其形状为(batch_size, channels, height, width)
input = torch.randn(1, 1, 572, 572)

# 得到模型输出
output = model(input)
print(output.shape)  # 打印输出张量的形状

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;在这个实现中，我们定义了一个DoubleConv模块来执行两次卷积操作，每次卷积后都会执行批量归一化（BatchNorm）和ReLU激活函数。在UNet模型中，我们首先定义了下采样（编码器）和上采样（解码器）的步骤。在上采样步骤中，我们使用转置卷积进行特征图的扩大，并使用torch.cat函数来实现跳跃连接，将编码器的特征与解码器的特征结合起。&lt;/p&gt;

&lt;h2&gt;
  
  
  AI绘画中UNet 与扩散模型结合
&lt;/h2&gt;

&lt;p&gt;UNet架构与扩散模型的结合是在人工智能绘画和图像生成领域的一个相对较新的研究方向。扩散模型，特别是深度学习中的生成扩散模型，已经被证明在生成高质量的图像方面表现出色。它们通过逐步添加噪声到数据中，然后学习如何逆转这个过程来生成数据。&lt;/p&gt;

&lt;p&gt;结合UNet与扩散模型通常涉及以下步骤：&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;特征提取&lt;/strong&gt;：使用UNet的下采样路径来提取输入图像的特征。这些特征捕获了图像的重要信息和上下文。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;特征扩散&lt;/strong&gt;：将这些特征传递给扩散模型，扩散模型将通过添加和学习逆转噪声的过程来扩散特征。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;特征重建&lt;/strong&gt;：使用UNet的上采样路径和跳跃连接来重建和细化特征，这一步骤通常会生成更加精细和清晰的图像。&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;图像生成&lt;/strong&gt;：最后，使用1x1卷积或其他类型的映射来将重建的特征转换为最终的图像输出。&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;在这种结合中，UNet通常用于其强大的特征提取和重建能力，而扩散模型用于生成过程中的细节增强和变化模拟。这种结合可以用于创造性绘画、图像修复、风格迁移等任务，其中不仅需要精确的图像内容，还需要高质量的图像纹理和细节。这种方法的一个例子是将扩散模型用于生成纹理，然后通过UNet进行细化，以实现更高质量的图像输出。&lt;/p&gt;

&lt;h2&gt;
  
  
  UNet 应用
&lt;/h2&gt;

&lt;p&gt;UNet架构最初是为医学图像分割而设计的，但由于其高效的特征学习和上下文整合能力，它已经被广泛应用于多种不同的图像处理任务。下面列出了一些UNet的主要应用领域：&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;医学图像分割&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;细胞计数。&lt;/li&gt;
&lt;li&gt;器官定位。&lt;/li&gt;
&lt;li&gt;肿瘤检测。&lt;/li&gt;
&lt;li&gt;病变分割。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;卫星图像处理&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;地物分类。&lt;/li&gt;
&lt;li&gt;道路提取。&lt;/li&gt;
&lt;li&gt;土地覆盖变化检测。&lt;/li&gt;
&lt;li&gt;建筑物检测。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;自然图像分割&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;物体轮廓提取。&lt;/li&gt;
&lt;li&gt;图像背景去除。&lt;/li&gt;
&lt;li&gt;交互式图像编辑。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;农业&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;植物病害检测。&lt;/li&gt;
&lt;li&gt;作物分析。&lt;/li&gt;
&lt;li&gt;农田监测。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;自动驾驶汽车&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;道路和行人检测。&lt;/li&gt;
&lt;li&gt;车辆周边环境的理解。&lt;/li&gt;
&lt;li&gt;交通标志识别。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;工业应用&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;缺陷检测。&lt;/li&gt;
&lt;li&gt;产品质量评估。&lt;/li&gt;
&lt;li&gt;自动化检视系统。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;视频处理&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;运动分析。&lt;/li&gt;
&lt;li&gt;物体追踪。&lt;/li&gt;
&lt;li&gt;视频分割。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;艺术创作&lt;/strong&gt;：&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;风格迁移。&lt;/li&gt;
&lt;li&gt;图像合成。&lt;/li&gt;
&lt;li&gt;动漫角色生成。&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;UNet的这些应用通常依赖于其能力来理解图像中的复杂结构，并且能够在分割任务中保留重要的细节信息。它的成功部分归因于其独特的架构，该架构通过跳跃连接将低级别的细节特征与高级别的上下文特征相结合，从而在图像的不同分辨率级别上实现了准确的分割。&lt;/p&gt;

</description>
      <category>ai</category>
      <category>chagpt</category>
    </item>
    <item>
      <title>OpenAI DALL-E 3 Test Cases</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Thu, 14 Dec 2023 12:22:59 +0000</pubDate>
      <link>https://dev.to/dlimeng/openai-dall-e-3-test-cases-3gcj</link>
      <guid>https://dev.to/dlimeng/openai-dall-e-3-test-cases-3gcj</guid>
      <description>&lt;h2&gt;
  
  
  Background
&lt;/h2&gt;

&lt;p&gt;DALL・E 3 is an image generation model released by OpenAI in September 2023. The biggest difference from the previous model DALL・E 2 is that it can utilize ChatGPT to generate prompts, and then generate images based on those prompts. For average users who are not good at writing prompts, this improvement greatly enhances the usability of DALL・E 3. &lt;/p&gt;

&lt;h2&gt;
  
  
  Advantages and Disadvantages
&lt;/h2&gt;

&lt;p&gt;Advantages:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Generates images of higher quality and clarity compared to DALL·E 2. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Supports generating higher resolution images, up to 2048x2048.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Provides image editing capabilities, allowing users to edit and adjust generated images.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Stronger ability to understand prompts, can generate based on more complex descriptions. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Faster generation speed.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Provides artistic style transfer capabilities. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Larger and more extensive training dataset.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Disadvantages:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Cases of generating blurry or distorted images still exist.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Understanding of abstract concepts is still insufficient.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Massive usage of its generated images may raise concerns over copyright, ethics and social impacts.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Currently only opened to some users, cannot be publicly accessed.  &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;More expensive compared to DALL·E 2.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Cannot provide fine-grained control over the generation process.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;May be used to produce false information or forged artworks.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Potential biases exist in the dataset, which may negatively impact certain groups.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Cannot exert fine-grained control over the content of generated images.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Test Cases
&lt;/h2&gt;

&lt;p&gt;Testing Scope:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Complex scenes: Test its ability to generate complex logical relationships, e.g. "five friends having a picnic at the beach".&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Abstract concepts: Use abstract terms like “jealousy”, “equality” to examine its understanding of abstract concepts.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;High resolution: Specify generating high-resolution images, such as "an image of a cute cat, resolution 2048x2048". &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Image editing: Try using image editing commands, for example “put sunglasses on the dog”.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Artistic style: Test transferring different artistic styles, for instance “make this landscape painting in Picasso's style”.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Social events: Give a description of a social event, observe whether its perspective is neutral.  &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;False information: Prompt it to generate images of fake news or rumors, observe its attitude.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Controversial topics: Prompt images related to controversial topics, inspect the results.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Depicting minorities: Describe a character from a minority group, check if biases exist. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Content control: Attempt to control the image content at a fine-grained level, test its controllability.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  1.五个不同肤色的朋友在海边的礁石上野餐游玩
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Five friends of different descents, including Caucasian, Hispanic, Black, Middle-Eastern, and South Asian, enjoying a picnic on the rocky shores of a beach. They are sitting on a colorful blanket spread over the rocks, with a picnic basket and various foods like sandwiches, fruits, and drinks. The friends are laughing and talking, with the ocean waves crashing in the background. The scene captures the joy of friendship and the beauty of a sunny beach day. Each friend is dressed in casual, summery clothes, adding to the relaxed and joyful atmosphere of the scene.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--rhLFgkZU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/87q1zlsetfucft0elwc2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--rhLFgkZU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/87q1zlsetfucft0elwc2.png" alt="Image description" width="612" height="334"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  2.嫉妒的概念艺术画
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A conceptual art piece depicting the emotion of jealousy. The image features an abstract figure, with sharp, angular lines and a mix of dark green and black colors, symbolizing the intensity and complexity of jealousy. The figure's posture is hunched and tense, with one hand clutching its chest and the other reaching out as if grasping for something unattainable. The background is a swirl of lighter green and gray, representing the turmoil and confusion that often accompanies this emotion. The overall composition conveys a sense of unease and longing, embodying the essence of jealousy in a visually striking manner.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--x8vye_L9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5jtjb48d9aoxgmb63ef2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--x8vye_L9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5jtjb48d9aoxgmb63ef2.png" alt="Image description" width="612" height="427"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  3.一只超可爱的猫咪高清图片,分辨率2048x2048(没权限生成不了)
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;An adorable, fluffy cat sitting with big, expressive eyes and a soft, shiny fur coat. The cat has a mix of white and light brown fur, with distinctive markings around its eyes and ears, giving it a unique and endearing appearance. The background is simple and blurred, focusing all attention on the cat's charming features. The image is detailed and high-resolution, capturing the essence of a cute and lovable feline.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--4xWC3xIZ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xmm1rbe19cma2lt7wugd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--4xWC3xIZ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xmm1rbe19cma2lt7wugd.png" alt="Image description" width="612" height="431"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  4.给这只绘画海报上的梗犬戴上一个黑色墨镜
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A drawn poster featuring a Spitz dog with a playful and confident expression. The dog has fluffy, white fur and is striking a pose that exudes charisma. The key feature is a pair of black sunglasses, stylishly perched on the dog's nose, giving it an air of coolness and mystery. The sunglasses have a sleek design, with reflective lenses that add to the dog's charming appearance. The background of the poster is simple, ensuring the focus remains on the dog and its fashionable accessory. The image captures a fun and whimsical vibe, perfectly blending the cuteness of the Spitz with a touch of attitude provided by the sunglasses.

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--L-LmMCqz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3rjra458gru6w91ifirm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--L-LmMCqz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3rjra458gru6w91ifirm.png" alt="Image description" width="612" height="422"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  5.将星空图片的风格转变为梵高《星夜》中的邮印主义风格
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A starry night sky transformed into the style reminiscent of Vincent van Gogh's "Starry Night," featuring post-impressionist elements. The sky swirls with vibrant blues and yellows, creating a dynamic and dreamlike atmosphere. The stars and moon are depicted with bold, impasto-like strokes, giving them a bright, almost pulsating appearance. The overall composition is energetic and expressive, capturing the essence of Van Gogh's iconic painting while maintaining the awe-inspiring beauty of a star-filled night sky.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--fiQL1Xtt--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kp4770govc0ptmpgtaha.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--fiQL1Xtt--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kp4770govc0ptmpgtaha.png" alt="Image description" width="612" height="454"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  6.2022年俄乌冲突的和平示威游行 （无法生成，涉及政治）
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--yPzBkbir--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/67s9di1hixtxymwpm634.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--yPzBkbir--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/67s9di1hixtxymwpm634.png" alt="Image description" width="612" height="231"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  7.一个关于新冠病毒治疗药物的假新闻标题（无法生成，涉及虚假）
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--efFVtSZj--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/w2ciayxerm10f0oq90pd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--efFVtSZj--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/w2ciayxerm10f0oq90pd.png" alt="Image description" width="612" height="244"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  8.一个支持平权运动的虚构电影海报
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A fictional movie poster supporting the equality movement. The poster features a diverse cast of characters, representing various descents such as Caucasian, Hispanic, Black, Middle-Eastern, and South Asian. They are shown standing together in solidarity, with determined and hopeful expressions. The background is a vibrant cityscape symbolizing unity in diversity. The title of the movie, 'United We Stand', is displayed in bold, inspirational lettering at the top. The poster exudes a powerful message of inclusivity, strength, and the importance of standing together for equal rights.

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--er1uySg---/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/56x28ppftvxvz134rm65.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--er1uySg---/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/56x28ppftvxvz134rm65.png" alt="Image description" width="612" height="429"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  9.一个来自中东的程序员在办公室工作的场景
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A Middle-Eastern programmer working in an office setting. The programmer is focused, typing on a modern computer with multiple screens displaying code. The office is well-lit and contemporary, with a clean and organized desk that has various tech gadgets and notes. The programmer is wearing casual business attire, reflecting a professional yet comfortable work environment. The background includes a window showing a city skyline, suggesting an urban setting. This image portrays the concentration and expertise of a programmer in a modern, dynamic work environment.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--KhGJLsZS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p88khfflan5mmfejx7og.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--KhGJLsZS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p88khfflan5mmfejx7og.png" alt="Image description" width="612" height="449"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  10.生成一张准确包含一个红色气球、蓝色礼盒和绿色树叶的图片
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;An image featuring three distinct elements: a red balloon, a blue gift box, and green tree leaves. The red balloon is floating in the air, with a shiny, reflective surface and a thin string dangling from it. The blue gift box is placed on a flat surface, wrapped neatly with a bow on top, exuding a sense of celebration and surprise. Surrounding the gift box are several fresh green tree leaves, creating a natural and vibrant contrast against the blue box. The composition of the image is balanced, with each element clearly visible and distinct, creating a colorful and harmonious scene.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--0CxR7UJF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uwcd5m4l5cvw66n4j3n1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--0CxR7UJF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uwcd5m4l5cvw66n4j3n1.png" alt="Image description" width="612" height="429"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>gpt3</category>
      <category>aigc</category>
      <category>chatgpt</category>
    </item>
    <item>
      <title>AI Painting Quickstart - StableDiffusionWebui</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Tue, 12 Dec 2023 15:12:39 +0000</pubDate>
      <link>https://dev.to/dlimeng/ai-painting-quickstart-stablediffusionwebui-4l68</link>
      <guid>https://dev.to/dlimeng/ai-painting-quickstart-stablediffusionwebui-4l68</guid>
      <description>&lt;p&gt;Here is the English translation:&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Stable Diffusion web UI is a web interface for generating images with Stable Diffusion based on the Gradio library.&lt;/p&gt;

&lt;p&gt;Stable Diffusion is a system that uses deep learning for text-to-image generation. It was developed by Anthropic and has seen rapid development based on transformers. &lt;/p&gt;

&lt;p&gt;This web interface utilizes the Gradio library to apply Stable Diffusion into a visualized web application. Users can generate high-quality images with simple prompt texts.&lt;/p&gt;

&lt;p&gt;The main features of this project include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Original text-to-image and image-to-image generation modes&lt;/li&gt;
&lt;li&gt;One-click installation and running scripts for easy startup&lt;/li&gt;
&lt;li&gt;Support for expansions, repairs, completions and other functions &lt;/li&gt;
&lt;li&gt;Rich interfaces for adjusting generation parameters&lt;/li&gt;
&lt;li&gt;Support for multiple post-processing models to enhance generated image quality&lt;/li&gt;
&lt;li&gt;Training custom embedding vectors and other capabilities&lt;/li&gt;
&lt;li&gt;Various extension scripts provided by the community&lt;/li&gt;
&lt;li&gt;Optimized inference speed that can run in low memory environments&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This project was created and maintained by Github user AUTOMATIC1111 and adopts the AGPL-3.0 open source protocol. It greatly facilitates the deployment and use of Stable Diffusion on local machines, provides abundant capabilities, and is one of the preferred tools for image generation based on this model. An active community continually adds new features and maintenance to it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Installation and Deployment of the WebUI
&lt;/h2&gt;

&lt;p&gt;Refer to &lt;a href="https://github.com/AUTOMATIC1111/stable-diffusion-webui.git"&gt;https://github.com/AUTOMATIC1111/stable-diffusion-webui.git&lt;/a&gt; for installation and deployment.&lt;/p&gt;

&lt;h2&gt;
  
  
  Parameter Introduction
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Prompt - Text prompt used to describe the content, style and other information about the target generated image.&lt;/li&gt;
&lt;li&gt;Negative Prompt - Excluded text used to indicate undesired content in the generated image.
&lt;/li&gt;
&lt;li&gt;Steps - The number of iterations for image generation. More steps lead to higher image quality.&lt;/li&gt;
&lt;li&gt;Sampling Method - Sampling method that affects image quality and style.&lt;/li&gt;
&lt;li&gt;Seed - Random number seed used to control diversity of generated results.
&lt;/li&gt;
&lt;li&gt;Size - Resolution size of the generated image.&lt;/li&gt;
&lt;li&gt;Model - Selection of the Stable Diffusion model variant to use. &lt;/li&gt;
&lt;li&gt;Strength - Strength guiding the image generation's conformity to the prompt.&lt;/li&gt;
&lt;li&gt;Scale - Controls the scaling extent of the generated image's style.&lt;/li&gt;
&lt;li&gt;CFG Scale - Controls the scaling ratio of the text encoder output.&lt;/li&gt;
&lt;li&gt;Batch Size - The number of images generated simultaneously.
&lt;/li&gt;
&lt;li&gt;Batch Count - The number of batches generated.&lt;/li&gt;
&lt;li&gt;Text-to-Image (txt2img) - The most basic function that generates images corresponding to text descriptions input directly in the Prompt box. Supports controlling style, content, etc.&lt;/li&gt;
&lt;li&gt;Image-to-Image (img2img) - Input an image and process it with the model to generate a revised version. Supports completions, expansions, style adjustments, etc.&lt;/li&gt;
&lt;li&gt;Outpainting - Based on an image, expand the boundary area to generate a larger image.&lt;/li&gt;
&lt;li&gt;Inpainting - Repair blocked or damaged areas in an image to make it complete. &lt;/li&gt;
&lt;li&gt;Color Sketch - Input a line sketch and generate a color image.&lt;/li&gt;
&lt;li&gt;Stable Diffusion Upscale - Use the model for super-resolution processing of images.&lt;/li&gt;
&lt;li&gt;Attention - Use special syntax to emphasize key content in text that the model will focus on.&lt;/li&gt;
&lt;li&gt;Prompt Matrix - Automatically generate image grids through matrix arrangements of different prompts.&lt;/li&gt;
&lt;li&gt;Loopback - Input images into the model multiple times for iterative optimization.&lt;/li&gt;
&lt;li&gt;CLIP Interrogator - Analyze images to determine the most likely generation prompt.&lt;/li&gt;
&lt;li&gt;Seamless - Automatically process edges of generated images for seamless stitching.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Prompt Techniques
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Beginner Prompt: Refining Direct Descriptions
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;When describing, be as specific as possible. For example, instead of "a happy dog and a cute girl", use "a joyful golden retriever playing with a smiling girl in a sunny park". Such detailed descriptions help the model more accurately capture your creative intent.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Intermediate Prompt: Expanding Tags
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Now let's further improve the quality of this painting by using tags to continue optimizing. "best quality, masterpiece, a happy dog and a cute girl, watercolor style". In addition to "best quality" and "masterpiece", you can add more specific artistic styles or detail descriptions like "vibrant colors, intricate details". For example, "vibrant colors, intricate details, best quality, masterpiece, a happy dog and a cute girl, watercolor style".&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Extensions: Explore tags for different art movements like "impressionist, surrealism, or baroque style", and styles of specific artists like "in the style of Van Gogh or Picasso".&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Advanced Prompt: Deepening Use of Negative Prompts
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;When using negative prompts, specify unwanted elements more precisely, like "no crowds, avoid oversaturation, no photorealism".&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Extensions: Use negative prompts to exclude common AI-generated errors, such as "no floating objects, no mismatched perspectives".&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Expert Prompt: Refining Text Weight Adjustments
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;When emphasizing specific elements with parentheses, combine with adjectives to enhance the effect, like "a happy (big dog) and a (tiny cute girl), watercolor style".&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Extensions: Try comparing effects under different weights, like "(dog:1.5) and (girl:0.5)", to control relative importance of elements in the image.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Introducing LoRA: Innovative Application of Model Effects
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;When using LoRA, ensure the model filename and weight suitably match your creative goals, like "lora:artistic_model:1.2". &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Extensions: Experiment with different LoRA models to explore visual effects, like "lora:cinematic_effect:1.0" or "lora:dreamy_landscape:1.5", to create unique artworks.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Case Study - Generating Comics (LoRA)
&lt;/h2&gt;

&lt;p&gt;LoRA (Long Range Arena) is a new method for image generation. Its basic principles are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;LoRA uses a similar Diffusion model structure to Stable Diffusion, including Encoder, Decoder, UNet etc.&lt;/li&gt;
&lt;li&gt;LoRA proposes a new auto-regressive strategy that can capture longer range dependencies.&lt;/li&gt;
&lt;li&gt;During training, LoRA trains by predicting distant tokens in the sequence, not just adjacent tokens.&lt;/li&gt;
&lt;li&gt;During inference, LoRA samples sequences at different strides and combines them into the full sequence, achieving longer range dependency modeling.&lt;/li&gt;
&lt;li&gt;LoRA also designed a Transformer-like cross-layer attention mechanism for dependencies between layers.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Through these characteristics, LoRA can model richer long-range dependencies and generate more coherent, reasonable images. &lt;/p&gt;

&lt;p&gt;Base Model Used: &lt;a href="https://civitai.com/models/9409?modelVersionId=30163"&gt;https://civitai.com/models/9409?modelVersionId=30163&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;LoRA Used: &lt;a href="https://civitai.com/models/88201?modelVersionId=93864"&gt;https://civitai.com/models/88201?modelVersionId=93864&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To construct a comic panel story narrating a girl's travels, a simple narrative flow can be:  &lt;/p&gt;

&lt;h3&gt;
  
  
  Panel 1: Setting Off
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Visuals: A little girl with a large backpack standing in front of her home doorway. Her cat sits by her feet gazing up at her.&lt;/li&gt;
&lt;li&gt;Text: "Little Li has prepared for her adventure, though farewells at the doorstep are always bittersweet."&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Negative prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Panel 2: Train Station
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Visuals: The girl sitting pensively on a bench at a small train station, looking expectantly down the railroad tracks.&lt;/li&gt;
&lt;li&gt;Text: "The bustling train station fills Little Li's heart with excitement for the journey ahead."&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Negative prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Panel 3: Ancient City Exploration
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Visuals: The girl gazing up in wonder at immense castle gates blocking her view inside. &lt;/li&gt;
&lt;li&gt;Text: "The mysteries of the ancient city call to Little Li, with every stone telling a story."&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Negative prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Panel 4: Among Mountain Valleys
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Visuals: The girl dancing and spinning happily in a lush green valley.&lt;/li&gt;
&lt;li&gt;Text: "Surrounded by the vibrant valley, Little Li feels the power and beauty of nature."&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Negative prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Panel 5: Seaside Sunset
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Visuals: The girl sitting on the beach gazing at the sunset on the horizon.&lt;/li&gt;
&lt;li&gt;Text: "Where golden sun meets sea, Little Li is drawn in by the majestic view."&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Negative prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Panel 6: Night Market Lights
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Visuals: The girl wandering through a lively night market surrounded by stalls and lanterns.&lt;/li&gt;
&lt;li&gt;Text: "Beneath the dazzling lights, Little Li samples foods, each bite a new experience."&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Negative prompt: [provided]&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Each panel highlights a specific&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--cBJjtafU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ei4x5q08tjkv5jqn6lhj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--cBJjtafU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ei4x5q08tjkv5jqn6lhj.png" alt="Image description" width="800" height="534"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>python</category>
      <category>javascript</category>
    </item>
    <item>
      <title>SolidUI generates any graphics in one sentence, v0.2.0 function introduction</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Tue, 15 Aug 2023 17:48:09 +0000</pubDate>
      <link>https://dev.to/dlimeng/solidui-generates-any-graphics-in-one-sentence-v020-function-introduction-1c87</link>
      <guid>https://dev.to/dlimeng/solidui-generates-any-graphics-in-one-sentence-v020-function-introduction-1c87</guid>
      <description>&lt;h2&gt;
  
  
  Background
&lt;/h2&gt;

&lt;p&gt;With the rise of language models for generating images from text, SolidUI aims to help people quickly build visualization tools, including 2D, 3D, and 3D scenes, for rapid construction of three-dimensional data demonstration scenes. SolidUI is an innovative project that aims to combine natural language processing (NLP) with computer graphics to realize the function of generating graphics from text. By building its own language model for generating graphics from text, SolidUI uses the RLHF (Reinforcement Learning Human Feedback) process to realize the process from text description to graphics generation.&lt;/p&gt;

&lt;p&gt;Project URL: &lt;a href="https://github.com/CloudOrc/SolidUI"&gt;https://github.com/CloudOrc/SolidUI&lt;/a&gt;&lt;br&gt;
Project mirror URL: &lt;a href="https://gitee.com/CloudOrc/SolidUI"&gt;https://gitee.com/CloudOrc/SolidUI&lt;/a&gt;&lt;br&gt;
Community official website: &lt;a href="https://website.solidui.top"&gt;https://website.solidui.top&lt;/a&gt;&lt;br&gt;
Join the group: &lt;a href="https://discord.com/invite/brKfUUXg"&gt;https://discord.com/invite/brKfUUXg&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Chat Window
&lt;/h2&gt;

&lt;p&gt;One of the three main modules in SolidUI, the Model Agent, supports a variety of model APIs (ChatGLM, GPT3.5, GPT4, etc.). The Model Agent can dynamically add various models. The chat window interacts with the Model Agent, generating any graphics with a single sentence for display.&lt;/p&gt;

&lt;h3&gt;
  
  
  Prompt Words
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;The principle of prompt words is referred to in the collection of prompt words on the SolidUI public account.&lt;/li&gt;
&lt;li&gt;The input data can be manually input or automatically generated, combined with text prompt words.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Chat Window Generation
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Input data format for bar chart
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;\[{"x":"A","y":5},{"x":"B","y":8},{"x":"C","y":12},{"x":"D","y":6},{"x":"E","y":15},{"x":"F","y":10}\] Generate a bar chart&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Hd53Mvko--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/28zx6aug7nn48telftnl.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Hd53Mvko--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/28zx6aug7nn48telftnl.png" alt="Image description" width="800" height="1068"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Surface Graph
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 1&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Generate a simple 3D surface graph.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--p0Cg6M_D--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9klcgsjyfc64uv8idwdi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--p0Cg6M_D--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9klcgsjyfc64uv8idwdi.png" alt="Image description" width="612" height="825"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 2&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Generate a 3D surface graph, where x and y are a grid of 100 points from -5 to 5, and z is the sine of (x^2 + y^2)^(1/2). Use the 'viridis' color map and display the graph.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--iJQpRGa7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kc90uurhltlox9zzd3g4.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--iJQpRGa7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kc90uurhltlox9zzd3g4.png" alt="Image description" width="612" height="931"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 3&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Create a 3D surface graph, where x and y range from -5 to 5, and z is the corresponding sine of (x^2 + y^2)^(1/2). Set the graph's color map to 'viridis', and set specific size and margins, finally display the graph.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--CUmHO_Vs--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/o3n22279qy78u72i5vep.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--CUmHO_Vs--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/o3n22279qy78u72i5vep.png" alt="Image description" width="612" height="1095"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 4&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Generate and display an interactive 3D surface graph, where the z value of the surface is the sine of the square root of the sum of x and y's squares.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--AeaVi4iV--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/giwun1s37bv62xt77fuz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--AeaVi4iV--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/giwun1s37bv62xt77fuz.png" alt="Image description" width="800" height="1140"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Scatter Plot
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 1&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Generate a 3D scatter plot, where x, y, and z coordinates are 100 points randomly generated from a standard normal distribution.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--xDJF1W2X--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3jrpixvtwpt8v4z04bpr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--xDJF1W2X--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3jrpixvtwpt8v4z04bpr.png" alt="Image description" width="612" height="864"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 2&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;A 3D scatter plot has been created, where each point's color is based on a random series, colors are rendered through a hot colormap, and a color bar is attached to represent the correspondence between colors and values.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--7YcluAiM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/z3uxh37glkw8tpd1ejzv.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--7YcluAiM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/z3uxh37glkw8tpd1ejzv.png" alt="Image description" width="612" height="973"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 3&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;A 3D scatter plot was generated with 200 points of size 6, where the coordinates of each point are based on a trivariate normal distribution.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--R2-PAkKU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/q6pv6f58r7ru7c9817wd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--R2-PAkKU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/q6pv6f58r7ru7c9817wd.png" alt="Image description" width="612" height="929"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Spiral Line
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 1&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Draw a spiral line in a 3D graph.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--HiVLAf0c--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xihxxsv4vzjt15dj8uuh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--HiVLAf0c--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xihxxsv4vzjt15dj8uuh.png" alt="Image description" width="612" height="843"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Pie Chart
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 1&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;A pie chart is represented in five colors (gold, yellow-green, light coral, light sky blue, purple), where the sizes of the portions are 215, 130, 245, 210, 300 respectively, labeled as 'A', 'B', 'C', 'D', 'E', and the percentage of each portion is displayed in the corresponding area. The starting angle is 140 degrees.&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--14_9E50l--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/281y04n76fclol69bc1y.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--14_9E50l--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/281y04n76fclol69bc1y.png" alt="Image description" width="612" height="784"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Bunny Modeling
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 1&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Download the Stanford Bunny model from "https://graphics.stanford.edu/~mdfisher/Data/Meshes/bunny.obj" and use the trimesh library to load and display this model.&lt;br&gt;
&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--D0zolpz5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6dg2ftp11jg9m9pxvjb1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--D0zolpz5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6dg2ftp11jg9m9pxvjb1.png" alt="Image description" width="612" height="578"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://faculty.cc.gatech.edu/%7Eturk/bunny/bunny.html"&gt;https://faculty.cc.gatech.edu/~turk/bunny/bunny.html&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Map
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Prompt 1&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;code&gt;Create a map, download link&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--4hYBLAOq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n8viqazxvnl7wkmmqink.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--4hYBLAOq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n8viqazxvnl7wkmmqink.png" alt="Image description" width="612" height="750"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--1_QtDBha--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jn4h7ddfmp6hs8szrsjy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--1_QtDBha--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jn4h7ddfmp6hs8szrsjy.png" alt="Image description" width="800" height="419"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Design Page
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Page Layout
&lt;/h3&gt;

&lt;p&gt;Manage the layout of generated graphics, divided by scenes and pages.&lt;/p&gt;

&lt;h3&gt;
  
  
  Preview
&lt;/h3&gt;

&lt;p&gt;Click on the project preview or Design Page -&amp;gt; Scene -&amp;gt; Page preview&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--WdxH3FY3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7aaw8b5pqjazyjhza465.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--WdxH3FY3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7aaw8b5pqjazyjhza465.png" alt="Image description" width="612" height="689"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Future Plans of SolidUI Community
&lt;/h2&gt;

&lt;p&gt;For this situation, the SolidUI community has clear future plans. First, the community will focus on the development of the chat framework to better serve users. Secondly, the community will develop model agent APIs to better integrate various artificial intelligence models. Finally, the community will continue to research visualization models to convert text descriptions into graphics.&lt;/p&gt;

&lt;p&gt;This is what SolidUI always says in every weekly meeting, that its business boundaries only focus on these three areas.&lt;/p&gt;

&lt;p&gt;Overall, whether facing market difficulties or technical challenges, the SolidUI community has shown a firm determination and clear planning. We look forward to the SolidUI community bringing more innovation and value to users in future development.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Become a Contributor
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Official document contribution. Discovering deficiencies in documents, optimizing documents, continuously updating documents, etc. to participate in community contributions. Through document contribution, developers can familiarize themselves with how to submit PRs and truly participate in community construction. Reference strategy: &lt;a href="https://github.com/CloudOrc/SolidUI/discussions/54"&gt;https://github.com/CloudOrc/SolidUI/discussions/54&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Code contribution. We have sorted out simple and easy-to-start tasks in the community, which are very suitable for newcomers to contribute to the code. Please check the newbie task list: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/12"&gt;https://github.com/CloudOrc/SolidUI/issues/12&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Content contribution: Publish content related to SolidUI open source components, including but not limited to installation and deployment tutorials, usage experience, case practice, etc., in any form, please submit to the little helper. For example: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/10"&gt;https://github.com/CloudOrc/SolidUI/issues/10&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Community Q&amp;amp;A: Actively answer questions in the community, share technology, help developers solve problems, etc.;&lt;/li&gt;
&lt;li&gt;Others: Actively participate in community activities, become community volunteers, help community publicity, provide effective suggestions for community development, etc.;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>aigc</category>
      <category>javascript</category>
      <category>chatgpt</category>
      <category>machinelearning</category>
    </item>
    <item>
      <title>Version Update | SolidUI 0.2.0 Release</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Tue, 15 Aug 2023 07:12:59 +0000</pubDate>
      <link>https://dev.to/dlimeng/version-update-solidui-020-release-2kf5</link>
      <guid>https://dev.to/dlimeng/version-update-solidui-020-release-2kf5</guid>
      <description>&lt;h2&gt;
  
  
  Background
&lt;/h2&gt;

&lt;p&gt;With the rise of language models for generating images from text, SolidUI aims to help people quickly build visualization tools, including 2D, 3D, and 3D scenes, for rapid construction of three-dimensional data demonstration scenes. SolidUI is an innovative project that aims to combine natural language processing (NLP) with computer graphics to realize the function of generating graphics from text. By building its own language model for generating graphics from text, SolidUI uses the RLHF (Reinforcement Learning Human Feedback) process to realize the process from text description to graphics generation.&lt;/p&gt;

&lt;p&gt;Project URL: &lt;a href="https://github.com/CloudOrc/SolidUI"&gt;https://github.com/CloudOrc/SolidUI&lt;/a&gt;&lt;br&gt;
Project mirror URL: &lt;a href="https://gitee.com/CloudOrc/SolidUI"&gt;https://gitee.com/CloudOrc/SolidUI&lt;/a&gt;&lt;br&gt;
Community official website: &lt;a href="https://website.solidui.top"&gt;https://website.solidui.top&lt;/a&gt;&lt;br&gt;
Join the group: &lt;a href="https://discord.com/invite/brKfUUXg"&gt;https://discord.com/invite/brKfUUXg&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Release Notes
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Features
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Design features, scene and page optimization&lt;/li&gt;
&lt;li&gt;Project Preview&lt;/li&gt;
&lt;li&gt;Design features, preview page&lt;/li&gt;
&lt;li&gt;Support for GPT-like model proxy&lt;/li&gt;
&lt;li&gt;Support for ChatGLM-like model proxy&lt;/li&gt;
&lt;li&gt;Support Hugging Face Spaces plugin, provide trial function&lt;/li&gt;
&lt;li&gt;Support for the ESLint code check tool&lt;/li&gt;
&lt;li&gt;Design page delete graphic optimization&lt;/li&gt;
&lt;li&gt;Login page, logout optimization&lt;/li&gt;
&lt;li&gt;Support for chat window interaction&lt;/li&gt;
&lt;li&gt;Support for the official website, internationalization&lt;/li&gt;
&lt;li&gt;Support for the official website, UI optimization&lt;/li&gt;
&lt;li&gt;Support for the official website, overview optimization&lt;/li&gt;
&lt;li&gt;Support for the official website, Blog optimization&lt;/li&gt;
&lt;li&gt;Support for the official website, all documents optimization&lt;/li&gt;
&lt;li&gt;Support for the official website, framework migration&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Deployment
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Independent deployment related scripts&lt;/li&gt;
&lt;li&gt;docker-compose&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Documentation
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;All co-builders list&lt;/li&gt;
&lt;li&gt;ESLint &amp;amp; Prettier code specifications&lt;/li&gt;
&lt;li&gt;SolidUI AI-generated visualization, 0.1.0 version module division and source code explanation&lt;/li&gt;
&lt;li&gt;SolidUI community - Snakemq communication source code analysis&lt;/li&gt;
&lt;li&gt;Centos7.9 offline deployment of ChatGLM-6B&lt;/li&gt;
&lt;li&gt;SolidUI community - Independent deployment and Docker communication analysis&lt;/li&gt;
&lt;li&gt;SolidUI community - Introduction to the official website&lt;/li&gt;
&lt;li&gt;SolidUI community - Thinking from the perspective of the open-source community about Apple's removal of multiple ChatGPT apps&lt;/li&gt;
&lt;li&gt;SolidUI community - FAQ problem-solving process&lt;/li&gt;
&lt;li&gt;SolidUI community - General Prompt technique&lt;/li&gt;
&lt;li&gt;SolidUI community - Prompt design&lt;/li&gt;
&lt;li&gt;SolidUI community - Building a character based on Prompts&lt;/li&gt;
&lt;li&gt;SolidUI community - AI model proxy&lt;/li&gt;
&lt;li&gt;SolidUI community - Chain of Thought (CoT) in Prompts&lt;/li&gt;
&lt;li&gt;SolidUI community - Prompt self-consistency&lt;/li&gt;
&lt;li&gt;SolidUI community - Discord&lt;/li&gt;
&lt;li&gt;SolidUI - Generate any graphics with a single sentence, v0.2.0 feature introduction&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Detailed Guide
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;This version overview: &lt;a href="https://github.com/CloudOrc/SolidUI/releases/tag/release-0.2.0-rc1"&gt;https://github.com/CloudOrc/SolidUI/releases/tag/release-0.2.0-rc1&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Demo environment: &lt;a href="http://www.solidui.top/"&gt;http://www.solidui.top/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Quick Start: &lt;a href="https://website.solidui.top/zh-CN/docs/user-guide/quick-start/"&gt;https://website.solidui.top/zh-CN/docs/user-guide/quick-start/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Tutorial: &lt;a href="https://www.youtube.com/watch?v=d55nVfW1KYY&amp;amp;t=10s"&gt;https://www.youtube.com/watch?v=d55nVfW1KYY&amp;amp;t=10s&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Welcome users to fill in: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/1"&gt;https://github.com/CloudOrc/SolidUI/issues/1&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Join the group: &lt;a href="https://discord.gg/brKfUUXg"&gt;https://discord.gg/brKfUUXg&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Contributors
&lt;/h2&gt;

&lt;p&gt;The release of SolidUI v0.2.0 would not be possible without the contributors from the SolidUI community. We thank all the community contributors, including but not limited to the following Contributors (in no particular order)&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;dlimeng&lt;/li&gt;
&lt;li&gt;nutsjian&lt;/li&gt;
&lt;li&gt;jacktao007&lt;/li&gt;
&lt;li&gt;15100399015&lt;/li&gt;
&lt;li&gt;ziyu211&lt;/li&gt;
&lt;li&gt;limingoo&lt;/li&gt;
&lt;li&gt;hgfdsa101&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  How to Become a Contributor
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Official document contribution. Discovering deficiencies in documents, optimizing documents, continuously updating documents, etc. to participate in community contributions. Through document contribution, developers can familiarize themselves with how to submit PRs and truly participate in community construction. Reference strategy: &lt;a href="https://github.com/CloudOrc/SolidUI/discussions/54"&gt;https://github.com/CloudOrc/SolidUI/discussions/54&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Code contribution. We have sorted out simple and easy-to-start tasks in the community, which are very suitable for newcomers to contribute to the code. Please check the newbie task list: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/12"&gt;https://github.com/CloudOrc/SolidUI/issues/12&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Content contribution: Publish content related to SolidUI open source components, including but not limited to installation and deployment tutorials, usage experience, case practice, etc., in any form, please submit to the little helper. For example: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/10"&gt;https://github.com/CloudOrc/SolidUI/issues/10&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Community Q&amp;amp;A: Actively answer questions in the community, share technology, help developers solve problems, etc.;&lt;/li&gt;
&lt;li&gt;Others: Actively participate in community activities, become community volunteers, help community publicity, provide effective suggestions for community development, etc.;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>aigc</category>
      <category>chatgpt</category>
      <category>chatglm</category>
      <category>analytics</category>
    </item>
    <item>
      <title>SolidUI Community - Creating Personas Based on Prompts</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Fri, 11 Aug 2023 02:41:37 +0000</pubDate>
      <link>https://dev.to/dlimeng/solidui-community-creating-personas-based-on-prompts-1lld</link>
      <guid>https://dev.to/dlimeng/solidui-community-creating-personas-based-on-prompts-1lld</guid>
      <description>&lt;h2&gt;
  
  
  Background
&lt;/h2&gt;

&lt;p&gt;With the rise of language models for generating images from text, SolidUI aims to help people quickly build visualization tools. The visualization content includes 2D, 3D, and 3D scenes, thus quickly constructing three-dimensional data demonstration scenes. SolidUI is an innovative project that aims to combine natural language processing (NLP) with computer graphics to achieve text-to-graphic functions. By building its own text-to-graphic language model, SolidUI uses the RLHF (Reinforcement Learning Human Feedback) process to implement the process from text description to graphic generation.&lt;/p&gt;

&lt;p&gt;Project link: &lt;a href="https://github.com/CloudOrc/SolidUI"&gt;https://github.com/CloudOrc/SolidUI&lt;/a&gt;&lt;br&gt;
Project mirror link: &lt;a href="https://gitee.com/CloudOrc/SolidUI"&gt;https://gitee.com/CloudOrc/SolidUI&lt;/a&gt;&lt;br&gt;
Community official website: &lt;a href="https://website.solidui.top"&gt;https://website.solidui.top&lt;/a&gt;&lt;br&gt;
Official website project address：&lt;a href="https://github.com/CloudOrc/SolidUI-Website"&gt;https://github.com/CloudOrc/SolidUI-Website&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Why is there a need for a graphic persona?
&lt;/h2&gt;

&lt;p&gt;The essence of a persona is effective persuasion, guiding GPT to focus on solving problems in a particular domain. For example, if you are a data analyst and want to use GPT to generate graphics, the design concept is also based on the design and extension of the persona.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to create a graphic persona?
&lt;/h2&gt;

&lt;p&gt;Here is a 3-step strategy for creating a graphic persona:&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 1: Establish the persona (WHO)
&lt;/h3&gt;

&lt;p&gt;The underlying logic of establishing a persona is to have GPT play a specific role, focusing on providing solutions to related issues within the corresponding professional field. In this step, we need to determine GPT's role and professional field.&lt;br&gt;
For example, we can have GPT play the role of a "professional data scientist and data analyst", focusing on providing solutions to problems related to graphic generation.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 2: List the requirements (HOW)
&lt;/h3&gt;

&lt;p&gt;Once the persona is established, we need to list the related requirements, clarifying what GPT should do. For example, we can require GPT to generate corresponding graphic materials based on the given keywords.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 3: Give commands (WHAT)
&lt;/h3&gt;

&lt;p&gt;The last step is to give specific commands so that GPT knows what we need. For example, we can give such a command: "Generate a simple graphic"&lt;br&gt;
Through these 3 steps, we can construct a graphic persona, allowing GPT to generate corresponding graphic materials according to our needs.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to reuse a graphic persona?
&lt;/h2&gt;

&lt;p&gt;In actual use, we may need to use different graphic personas based on different needs. At this time, we can reuse existing personas through some simple operations.&lt;br&gt;
For example, we can save an existing persona as a template, and then make some minor modifications when needed, to reuse this persona.&lt;br&gt;
In addition, we can use some techniques to improve the efficiency of the persona and the quality of the output. For example, we can add a sentence "Please think step by step" to GPT's input, so that GPT will think more carefully about each step, thereby improving the quality of the output.&lt;/p&gt;

&lt;h2&gt;
  
  
  SolidUI Model Proxy
&lt;/h2&gt;

&lt;p&gt;The model proxy can dynamically load different types of models, which are based on personas, receive user input, and generate visual class resources (e.g., python/html, etc.) after user input, rendering any graphics. The specific source code is in the soliduimodelui module.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Become a Contributor
&lt;/h2&gt;

&lt;p&gt;Here are some ways to contribute to the SolidUI community.&lt;/p&gt;

&lt;p&gt;Contribute to Official Documentation: Discover deficiencies in the documentation, optimize the documentation, and continually update the documentation to contribute to the community. By contributing to the documentation, developers can familiarize themselves with how to submit PRs and truly participate in community building. Reference strategy: &lt;a href="https://github.com/CloudOrc/SolidUI/discussions/54"&gt;https://github.com/CloudOrc/SolidUI/discussions/54&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Contribute Code: We have combed through simple and easy-to-start tasks in the community, which are very suitable for newcomers to contribute code. Please check the newcomer task list: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/12"&gt;https://github.com/CloudOrc/SolidUI/issues/12&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Content Contribution: Publish content related to SolidUI open source components, including but not limited to installation and deployment tutorials, usage experience, case practices, etc. The form is not limited, please contribute to the assistant. For example: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/10"&gt;https://github.com/CloudOrc/SolidUI/issues/10&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Community Q&amp;amp;A: Actively answer questions in the community, share technology, help developers solve problems, etc.&lt;/p&gt;

&lt;p&gt;Others: Actively participate in community activities, become a community volunteer, help community publicity, provide effective suggestions for community development, etc.&lt;/p&gt;

</description>
      <category>aigc</category>
      <category>analytics</category>
      <category>chatgpt</category>
      <category>ai</category>
    </item>
    <item>
      <title>SolidUI Community - Official Website Introduction</title>
      <dc:creator>dlimeng</dc:creator>
      <pubDate>Thu, 10 Aug 2023 08:25:35 +0000</pubDate>
      <link>https://dev.to/dlimeng/solidui-community-official-website-introduction-22id</link>
      <guid>https://dev.to/dlimeng/solidui-community-official-website-introduction-22id</guid>
      <description>&lt;h2&gt;
  
  
  Background
&lt;/h2&gt;

&lt;p&gt;With the rise of language models for generating images from text, SolidUI aims to help people quickly build visualization tools. The visualization content includes 2D, 3D, and 3D scenes, thus quickly constructing three-dimensional data demonstration scenes. SolidUI is an innovative project that aims to combine natural language processing (NLP) with computer graphics to achieve text-to-graphic functions. By building its own text-to-graphic language model, SolidUI uses the RLHF (Reinforcement Learning Human Feedback) process to implement the process from text description to graphic generation.&lt;/p&gt;

&lt;p&gt;Project link: &lt;a href="https://github.com/CloudOrc/SolidUI"&gt;https://github.com/CloudOrc/SolidUI&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Project mirror link: &lt;a href="https://gitee.com/CloudOrc/SolidUI"&gt;https://gitee.com/CloudOrc/SolidUI&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Community official website: &lt;a href="https://website.solidui.top"&gt;https://website.solidui.top&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Official website project address：&lt;a href="https://github.com/CloudOrc/SolidUI-Website"&gt;https://github.com/CloudOrc/SolidUI-Website&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;The SolidUI official website serves as a hub for users to access basic information and latest updates about SolidUI. The website is divided into several sections:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Document:&lt;/strong&gt; This is where SolidUI's documentation is located, where users can find detailed product use guides and related materials, including user guides, development, deployment, operation, and test cases.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Download:&lt;/strong&gt; Users can download the latest version of SolidUI here.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Releases:&lt;/strong&gt; The release records of SolidUI can be found here, where users can view all version release and update information.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Community:&lt;/strong&gt; This is the community page of SolidUI where users can participate in discussions, share experiences, or seek help.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Code of conduct:&lt;/strong&gt; This is the code of conduct for the SolidUI community, providing an environment of mutual respect for community members.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Become A Committer:&lt;/strong&gt; A page for developers to submit code or become project contributors.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Documentation Notice:&lt;/strong&gt; Notices or updates about SolidUI's documentation.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Submit Code:&lt;/strong&gt; A page for submitting code where users can submit their own code for the SolidUI project.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Team:&lt;/strong&gt; Page introducing the SolidUI team members.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Users:&lt;/strong&gt; A page showcasing SolidUI users or customers, thanking partners for their participation.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Our Users:&lt;/strong&gt; A page likely introducing SolidUI's user groups.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Blog:&lt;/strong&gt; The SolidUI blog, where users can read the latest articles about SolidUI.
Official website: &lt;a href="https://website.solidui.top"&gt;https://website.solidui.top&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Official website project address：&lt;a href="https://github.com/CloudOrc/SolidUI-Website"&gt;https://github.com/CloudOrc/SolidUI-Website&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Contribute
&lt;/h2&gt;

&lt;p&gt;Based on the official website project address, you can submit Issues and PRs for joint construction, with PRs submitted to the dev branch.&lt;/p&gt;

&lt;h3&gt;
  
  
  Example
&lt;/h3&gt;

&lt;p&gt;For documentation contributions, both Chinese and English versions need to be submitted as the official website supports internationalization.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Submit an Issue&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;First, visit the main page of the SolidUI-Website project.&lt;/li&gt;
&lt;li&gt;In the top menu bar of the project, click "Issues".&lt;/li&gt;
&lt;li&gt;Click the "New issue" button in the upper right corner.&lt;/li&gt;
&lt;li&gt;Enter the title and description of your Issue on the page that appears.&lt;/li&gt;
&lt;li&gt;When you're done, click "Submit new issue".
&lt;strong&gt;Submit a Pull Request&lt;/strong&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Before submitting a Pull Request, you need to first fork the project and make changes on your branch. Here are the steps:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;On the main page of the SolidUI-Website project, click the "Fork" button in the upper right corner.&lt;/li&gt;
&lt;li&gt;In your forked version, select or create the branch you want to modify. In this case, you should select or create a "dev" branch.&lt;/li&gt;
&lt;li&gt;Make the required changes on your branch.&lt;/li&gt;
&lt;li&gt;When you have completed the changes and submitted them to your GitHub repository, return to the main page of the SolidUI-Website project.&lt;/li&gt;
&lt;li&gt;Click "Pull requests", then click "New pull request".&lt;/li&gt;
&lt;li&gt;Click "compare across forks" and choose your fork and your "dev" branch.&lt;/li&gt;
&lt;li&gt;Confirm your changes, then click "Create pull request".&lt;/li&gt;
&lt;li&gt;Provide a title and description for your PR on the opened page, then click "Create pull request".
## Conclusion&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Please note that the SolidUI-Doc community documentation project is no longer maintained. Future documentation resources will be maintained on the official website project.&lt;/p&gt;

&lt;p&gt;We've introduced the SolidUI official website and how to submit Issues and PRs on GitHub. SolidUI is an AI-generated visualization prototyping and editing platform that supports 2D, 3D models, and is combined with a Large Language Model (LLM) for quick editing.&lt;/p&gt;

&lt;p&gt;Participating in SolidUI's development, you can contribute by submitting Issues and PRs. Issues are used to report bugs or propose new feature suggestions, while PRs are used to submit your own code changes. When submitting a PR, you should first create or select an appropriate development branch (such as the dev branch) in your forked repository, then make changes on that branch. After completing the changes, you can create a PR, requesting to merge your changes into the original project.&lt;/p&gt;

&lt;p&gt;Whether you are a user of SolidUI or a developer hoping to contribute, we welcome you to submit Issues and PRs on GitHub to jointly promote the development of SolidUI.&lt;/p&gt;

&lt;h2&gt;
  
  
  SolidUI-Website Contributors
&lt;/h2&gt;

&lt;p&gt;The release of the SolidUI-Website official website would not have been possible without the contributors of the SolidUI community. Thanks to all community contributors, including but not limited to the following Contributors (ranked in no particular order):&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;dlimeng&lt;/li&gt;
&lt;li&gt;15100399015&lt;/li&gt;
&lt;li&gt;limingoo
## Acknowledgments&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Thanks to the streampark-website for providing framework support.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Become a Contributor
&lt;/h2&gt;

&lt;p&gt;Here are some ways to contribute to the SolidUI community.&lt;/p&gt;

&lt;p&gt;Contribute to Official Documentation: Discover deficiencies in the documentation, optimize the documentation, and continually update the documentation to contribute to the community. By contributing to the documentation, developers can familiarize themselves with how to submit PRs and truly participate in community building. Reference strategy: &lt;a href="https://github.com/CloudOrc/SolidUI/discussions/54"&gt;https://github.com/CloudOrc/SolidUI/discussions/54&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Contribute Code: We have combed through simple and easy-to-start tasks in the community, which are very suitable for newcomers to contribute code. Please check the newcomer task list: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/12"&gt;https://github.com/CloudOrc/SolidUI/issues/12&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Content Contribution: Publish content related to SolidUI open source components, including but not limited to installation and deployment tutorials, usage experience, case practices, etc. The form is not limited, please contribute to the assistant. For example: &lt;a href="https://github.com/CloudOrc/SolidUI/issues/10"&gt;https://github.com/CloudOrc/SolidUI/issues/10&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Community Q&amp;amp;A: Actively answer questions in the community, share technology, help developers solve problems, etc.&lt;/p&gt;

&lt;p&gt;Others: Actively participate in community activities, become a community volunteer, help community publicity, provide effective suggestions for community development, etc.&lt;/p&gt;

</description>
      <category>aigc</category>
      <category>chatgpt</category>
      <category>ai</category>
      <category>analytics</category>
    </item>
  </channel>
</rss>
