承接 inelo/numco 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

inelo/numco

最新稳定版本:1.1.0

Composer 安装命令:

composer require inelo/numco

包简介

NUMber COmpressor - small library for numeric arrays compression.

关键字:

README 文档

README

A small compression/decompression library for numerical arrays. Its best suited for large data sets of integers.

How it works

Internally this lib creates a delta encoded array and then deflates it using zlib.

Delta encoding is one of the most powerfull numeric compression methods out there. Its a simple algorithm that converts values in given array so that each represents a difference from the previous value.

Delta encoding example:

[100, 101, 102, 103, 104, 105] converts to [100, 1, 1, 1, 1, 1] 

Charts

(the more sequential data the better compression ratio)

charts

Mini DOC

Compression

Numco::compress(array) : string expects array of numbers as argument and returns compressed base64 encoded string 

Decompression

Numco::decompress(string) : array expects compressed base64 encoded string and returns decompressed array of numbers 

Composer Installation

$ composer require inelo/numco 

Example usage

use Inelo\Numco\Numco; $numArray = [ 100, 101, 102, ... ]; $compressed = Numco::compress($numArray); $decompressed = Numco::decompress($compressed); echo "compressed base64 encoded string : " . $compressed . "\n"; echo "decompressed array : " . var_export($decompressed, true) . "\n"; 

Running tests

vendor/bin/phpunit tests

Release History

  • 1.0.0 Initial release

统计信息

  • 总下载量: 17.61k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 3
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 3
  • Watchers: 6
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固