Open-Sora全面开源升级:支持16s视频生成和720p分辨率

巴比特·区块链Pubblicato 2024-04-26Pubblicato ultima volta 2024-04-26

Introduzione

Open-Sora 在开源社区悄悄更新了

文章来源:机器之心

图片来源:由无界AI生成
图片来源:由无界AI生成


Open-Sora 在开源社区悄悄更新了,现在单镜头支持长达16秒的视频生成,分辨率最高可达720p,并且可以处理任何宽高比的文本到图像、文本到视频、图像到视频、视频到视频和无限长视频的生成需求。我们来试试效果。

生成个横屏圣诞雪景,发b站

再生成个竖屏,发抖音

还能生成单镜头16秒的长视频,这下人人都能过把编剧瘾了

怎么玩?指路

GitHub:https://github.com/hpcaitech/Open-Sora

更酷的是,Open-Sora 依旧全部开源,包含最新的模型架构、最新的模型权重、多时间/分辨率/长宽比/帧率的训练流程、数据收集和预处理的完整流程、所有的训练细节、demo示例详尽的上手教程


Open-Sora 技术报告全面解读


最新功能概览

作者团队在GitHub上正式发布了Open-Sora 技术报告[1],根据笔者的了解,本次更新主要包括以下几项关键特性:

  • 支持长视频生成;
  • 视频生成分辨率最高可达720p;
  • 单模型支持任何宽高比,不同分辨率和时长的文本到图像、文本到视频、图像到视频、视频到视频和无限长视频的生成需求;
  • 提出了更稳定的模型架构设计,支持多时间/分辨率/长宽比/帧率训练;
  • 开源了最新的自动数据处理全流程。


时空扩散模型ST-DiT-2

作者团队表示,他们对Open-Sora 1.0中的STDiT架构进行了关键性改进,旨在提高模型的训练稳定性和整体性能。针对当前的序列预测任务,团队采纳了大型语言模型(LLM)的最佳实践,将时序注意力中的正弦波位置编码(sinusoidal positional encoding)替换为更加高效的旋转位置编码(RoPE embedding)。此外,为了增强训练的稳定性,他们参考SD3模型架构,进一步引入了QK归一化技术,以增强半精度训练的稳定性。为了支持多分辨率、不同长宽比和帧率的训练需求,作者团队提出的ST-DiT-2架构能够自动缩放位置编码,并处理不同大小尺寸的输入。


多阶段训练

根据Open-Sora 技术报告指出,Open-Sora 采用了一种多阶段训练方法,每个阶段都会基于前一个阶段的权重继续训练。相较于单一阶段训练,这种多阶段训练通过分步骤引入数据,更高效地实现了高质量视频生成的目标。

初始阶段大部分视频采用144p分辨率,同时与图片和 240p,480p 的视频进行混训,训练持续约1周,总步长81k。第二阶段将大部分视频数据分辨率提升至240p和480p,训练时长为1天,步长达到22k。第三阶段进一步增强至480p和720p,训练时长为1天,完成了4k步长的训练。整个多阶段训练流程在约9天内完成,与Open-Sora1.0相比,在多个维度提升了视频生成的质量。


统一的图生视频/视频生视频框架

作者团队表示,基于Transformer的特性,可以轻松扩展 DiT 架构以支持图像到图像以及视频到视频的任务。他们提出了一种掩码策略来支持图像和视频的条件化处理。通过设置不同的掩码,可以支持各种生成任务,包括:图生视频,循环视频,视频延展,视频自回归生成,视频衔接,视频编辑,插帧等。

支持图像和视频条件化处理的掩码策略
支持图像和视频条件化处理的掩码策略

作者团队表示,受到UL2[2]方法的启发,他们在模型训练阶段引入了一种随机掩码策略。具体而言,在训练过程中以随机方式选择并取消掩码的帧,包括但不限于取消掩码第一帧、前k帧、后k帧、任意k帧等。作者还向我们透露,基于Open-Sora 1.0的实验,应用50%的概率应用掩码策略时,只需少量步数模型能够更好地学会处理图像条件化。在Open-Sora 最新版本中,他们采用了从头开始使用掩码策略进行预训练的方法。

此外,作者团队还贴心地为推理阶段提供了掩码策略配置的详细指南,五个数字的元组形式在定义掩码策略时提供了极大的灵活性和控制力。

掩码策略配置说明
掩码策略配置说明


支持多时间/分辨率/长宽比/帧率训练

OpenAI Sora的技术报告[3]指出,使用原始视频的分辨率、长宽比和长度进行训练可以增加采样灵活性,改善帧和构图。对此,作者团队提出了分桶的策略。

具体怎么实现呢?通过深入阅读作者发布的技术报告,我们了解到,所谓的桶,是(分辨率,帧数,长宽比)的三元组。团队为不同分辨率的视频预定义了一系列宽高比,以覆盖大多数常见的视频宽高比类型。在每个训练周期epoch开始之前,他们会对数据集进行重新洗牌,并将样本根据其特征分配到相应的桶中。具体来说,他们会将每个样本放入一个分辨率和帧长度均小于或等于该视频特性的桶中。

Open-Sora 分桶策略
Open-Sora 分桶策略

作者团队进一步透露,为了降低计算资源的要求,他们为每个keep_prob和batch_size引入两个属性(分辨率,帧数),以减少计算成本并实现多阶段训练。这样,他们可以控制不同桶中的样本数量,并通过为每个桶搜索良好的批大小来平衡GPU负载。作者在技术报告中对此进行了详尽的阐述,感兴趣的小伙伴可以阅读作者在GitHub上发布的技术报告来获取更多的信息:https://github.com/hpcaitech/Open-Sora


数据收集和预处理流程

作者团队甚至对数据收集与处理环节也提供了详尽的指南。根据作者在技术报告中的阐述,在Open-Sora 1.0的开发过程中,他们意识到数据的数量和质量对于培育一个高效能模型极为关键,因此他们致力于扩充和优化数据集。他们建立了一个自动化的数据处理流程,该流程遵循奇异值分解(SVD)原则,涵盖了场景分割、字幕处理、多样化评分与筛选,以及数据集的管理系统和规范。同样,他们也将数据处理的相关脚本无私地分享至开源社区。对此感兴趣的开发者现在可以利用这些资源,结合技术报告和代码,来高效地处理和优化自己的数据集。

Open-Sora 数据处理流程
Open-Sora 数据处理流程


Open-Sora 性能全方位评测

视频生成效果展示

Open-Sora 最令人瞩目的亮点在于,它能够将你脑中的景象,通过文字描述的方式,捕捉并转化为动人的动态视频。那些在思维中一闪而过的画面和想象,现在得以被永久地记录下来,并与他人分享。在这里,笔者尝试了几种不同的prompt,作为抛砖引玉。

比如,笔者尝试生成了一个在冬季森林里游览的视频。雪刚下不久,松树上挂满了皑皑白雪,暗色的松针和洁白的雪花错落有致,层次分明。

又或者,在一个静谧夜晚中,你身处像无数童话里描绘过黑暗的森林,幽深的湖水在漫天璀璨的星河的照耀下波光粼粼。

在空中俯瞰繁华岛屿的夜景则更是美丽,温暖的黄色灯光和丝带一样的蓝色海水让人一下子就被拉入度假的悠闲时光里。

城市里的车水马龙,深夜依然亮着灯的高楼大厦和街边小店,又有另一番风味。

除了风景之外,Open-Sora 还能还原各种自然生物。无论是红艳艳的小花,

还是慢悠悠扭头的变色龙, Open-Sora 都能生成较为真实的视频。

笔者还尝试了多种 prompt 测试,还提供了许多生成的视频供大家参考,包括不同内容,不同分辨率,不同长宽比,不同时长。

笔者还发现,仅需一个简洁的指令,Open-Sora便能生成多分辨率的视频短片,彻底打破创作限制。

分辨率:16*240p
分辨率:16*240p
分辨率:32*240p
分辨率:32*240p
分辨率:64*360p
分辨率:64*360p
分辨率:480*854p
分辨率:480*854p

我们还可以喂给Open-Sora一张静态图片让它生成短片

Open-Sora 还可以将两个静态图巧妙地连接起来,轻触下方视频,将带您体验从下午至黄昏的光影变幻,每一帧都是时间的诗篇。

再比如说我们要对原有视频进行编辑,仅需一个简单的指令,原本明媚的森林便迎来了一场鹅毛大雪。

我们也能让Open-Sora 生成高清的图片 

值得注意的是,Open-Sora的模型权重已经完全免费公开在他们的开源社区上,不妨下载下来试一下。由于他们还支持视频拼接功能,这意味着你完全有机会免费创作出一段带有故事性的小短片,将你的创意带入现实。

权重下载地址:https://github.com/hpcaitech/Open-Sora


当前局限与未来计划


尽管在复现类Sora文生视频模型的工作方面取得了不错的进展,但作者团队也谦逊地指出,当前生成的视频在多个方面仍有待改进:包括生成过程中的噪声问题、时间一致性的缺失、人物生成质量不佳以及美学评分较低。对于这些挑战,作者团队表示,他们将在下一版本的开发中优先解决,以期望达到更高的视频生成标准,感兴趣的朋友不妨持续关注一下。我们期待Open-Sora社区带给我们的下一次惊喜。

开源地址:https://github.com/hpcaitech/Open-Sora


参考文献:
[1]  https://github.com/hpcaitech/Open-Sora/blob/main/docs/report_02.md
[2] Tay, Yi, et al. "Ul2: Unifying language learning paradigms." arXiv preprint arXiv:2205.05131 (2022).
[3] https://openai.com/research/video-generation-models-as-world-simulators

Letture associate

After Three Consecutive Quarters of Decline, Can the Crypto Market Find a Window for Stabilization in Q3?

The cryptocurrency market has just concluded its worst-performing quarter since 2022, with total capitalization dropping 12.6% to $2.1 trillion. All core metrics indicate capital is leaving the sector, not just rotating within it. Bitcoin fell 14.2% and Ethereum dropped 25.4% in Q2, breaking their previous correlation with US tech stocks. A key driver is the reversal in US spot Bitcoin ETF flows, which saw a net outflow of approximately $4.67 billion in Q2, including a record monthly outflow near $4.5 billion in June. While recent data suggests long-term holders are accumulating again, sustained ETF outflows mean continued selling pressure. Market focus is now singularly on the Federal Reserve. The upcoming July FOMC meeting is seen as the most critical event for Q3. A dovish signal could support Bitcoin reclaiming a $68,000-$84,000 range, while a hawkish stance might establish a new trading band around $50,000-$56,000. Additionally, regulatory uncertainty persists, with the progress of the crucial *CLARITY Act* stalling in the Senate, reducing its perceived 2026 passage probability to 40-45%. Despite the broad downturn, a few sectors showed growth. Prediction markets saw nominal volume surge 48.7% year-over-year to $113.8 billion, and tokenized collectibles transaction volume rose 143% quarterly to $1.4 billion. The Real-World Asset (RWA) tokenization sector also continued steady growth, now representing ~$28.1 billion in on-chain value. The market's foundation for an extreme crash appears limited, with Bitcoin price hovering near its 200-week moving average. However, the trading paradigm has shifted from narrative-driven speculation to decisions based on price action, policy developments, and interest rate expectations, making a broad sentiment-driven rally unlikely in the near term.

marsbit14 h fa

After Three Consecutive Quarters of Decline, Can the Crypto Market Find a Window for Stabilization in Q3?

marsbit14 h fa

BIT Trading Moment: BTC Still Suppressed by Weekly 200 EMA, Rejection May Restart Decline; Storage and Semiconductors that Surged Last Night Begin Falling in Evening Trading

**Crypto & Stock Market Wrap: Bitcoin Tests Resistance, Stocks Retreat After AI Surge** Bitcoin consolidates around $66,000, facing key resistance near $68,000—an area seen as a major psychological and technical hurdle where previous rallies have failed. Analysts note the cryptocurrency is caught between its 200-week moving average (~$63,333) and 200-week EMA (~$68,328). A clear break above $68k is needed to signal a stronger bullish trend, while a rejection could lead to a retest of $63k support. Market sentiment remains cautious, with low futures open interest pointing to a low-liquidity rebound rather than a full bull market. Bitcoin spot ETFs saw another $203 million inflow. US stock futures pointed lower after a strong Tuesday session led by a massive rebound in semiconductors and memory stocks. The rally was fueled by renewed optimism about AI-driven hardware demand, with Micron, SanDisk, and SK Hynix surging. However, those gains reversed in pre-market trading. Super Micro Computer (SMCI) soared over 20% after hours on strong guidance and a record backlog. Other standouts included Rocket Lab and nuclear energy plays Oklo and X-Energy. Rising oil prices (Brent above $91) and climbing Treasury yields (10-year near 4.64%), however, are reigniting inflation concerns and acting as a headwind for equities. In Asia, markets were mixed. South Korea's KOSPI pared early gains to close slightly higher as semiconductor stocks like SK Hynix gave back initial surges. Japan's Nikkei edged lower as the yen hit a fresh 38-year low against the dollar, raising fears of potential market intervention. Key events to watch include the Samsung Galaxy launch, AMD's AI event, and a slew of major tech earnings from Alphabet, Tesla, and IBM after the close on Wednesday, followed by the ECB meeting and Intel's earnings on Thursday.

marsbit15 h fa

BIT Trading Moment: BTC Still Suppressed by Weekly 200 EMA, Rejection May Restart Decline; Storage and Semiconductors that Surged Last Night Begin Falling in Evening Trading

marsbit15 h fa

Former CFTC Chairman, Circle President Tarbert: Preaching Long-Termism While Cashing Out $30 Million Himself

Former CFTC Chairman and Circle President Heath Tarbert has consistently advocated for a long-term vision in public, urging patience from investors as Circle’s stock price has fallen significantly from its peak. However, it has been revealed that since Circle’s IPO, Tarbert has continuously sold his CRCL shares through pre-arranged trading plans, cashing out approximately $30 million, without making any public market purchases. This contrast between his public messaging and personal actions has drawn criticism. Tarbert joined Circle in July 2023 as Chief Legal Officer, leveraging his regulatory experience to help guide the company through its IPO and expansion. Despite promoting stablecoins as long-term infrastructure, he established a 10b5-1 trading plan just before Circle went public, leading to substantial stock sales over the following year. In March 2026, he initiated another plan to sell more shares. His career trajectory highlights a pattern of moving between high-level regulatory roles and influential positions in the financial sector. After resigning as CFTC Chairman in early 2021, he joined Citadel Securities as Chief Legal Officer just 27 days later, during a period of intense regulatory scrutiny for the firm. He later joined Circle, aiding its efforts to navigate regulatory challenges for its public listing. While Tarbert's expertise in policy and compliance is valuable to companies like Circle, his actions—advocating long-term confidence while personally divesting—raise questions about the alignment between his public statements and his private financial decisions, leaving investors who followed his advice to bear the market risks.

marsbit15 h fa

Former CFTC Chairman, Circle President Tarbert: Preaching Long-Termism While Cashing Out $30 Million Himself

marsbit15 h fa

Gate Research Institute: The 'Wall Street-ization' Wave of Crypto Financial Products – Competition or Integration?

The article titled "Gate Research Institute: Are Crypto Financial Products Sparking a 'Wall Street' Wave—Competition or Convergence?" explores the evolving relationship between the crypto ecosystem and traditional finance (TradFi). The piece begins by reflecting on Bitcoin's original 2009 vision of decentralization, disintermediation, and moving away from banks. It then contrasts this with the 2024 landscape, where key crypto assets like Bitcoin are increasingly held through Wall Street products like ETFs issued by giants like BlackRock. The article questions whether this signifies that TradFi is systematically taking over the rights to issue, price, custody, and distribute crypto financial assets. The core argument is that this is not a zero-sum takeover but rather a bidirectional convergence where each side addresses the other's weaknesses. Crypto offers 24/7 global markets, programmable settlement, and open access but lacks compliant channels, institutional-grade custody, deep fiat liquidity, and mainstream distribution. TradFi possesses these but is constrained by legacy systems, limited operating hours, and slow settlement. Two primary convergence paths are highlighted: * **Path A (CEX to TradFi):** Exemplified by Gate, which has progressed from offering tokenized stocks and CFDs to providing direct, real stock trading (US, Hong Kong, South Korea) within its platform, using USDT. * **Path B (TradFi to Crypto):** Exemplified by Robinhood, which has integrated crypto trading, acquired exchanges like Bitstamp, and is moving traditional assets like stocks onto the blockchain via tokenization and its own Layer 2. Both paths are ultimately competing to become the next-generation, unified financial account—a "super account" where users can seamlessly trade cryptocurrencies, stocks, ETFs, RWA (Real World Assets), and tokenized treasury products in one interface. The growth of RWA and tokenized treasuries (e.g., BlackRock's BUIDL) is presented as the asset-layer fusion, providing stable, yield-bearing assets on-chain and acting as a bridge between the two worlds. In conclusion, the "Wall Street-ization" of crypto is framed as a mutual transformation. Decentralized ideals persist in the protocol layer, while at the application layer, a more efficient, global, and accessible unified capital market is emerging from this convergence. The future competition lies not between crypto exchanges and stockbrokers, but between platforms vying to offer the most comprehensive asset coverage, liquidity, and user experience within a single account.

marsbit15 h fa

Gate Research Institute: The 'Wall Street-ization' Wave of Crypto Financial Products – Competition or Integration?

marsbit15 h fa

Trading

Spot
活动图片