Discussion about dataset preparation speed
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 15/100
- Loại issue
- Tái cấu trúc
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- python
- Lĩnh vực
- data, performance
Hướng nghiên cứu
The reproduction script calls GPTMemmapDataset and get_document_sizes from the fast_llm.data.dataset.gpt.memmap module, so start there and compare what the dataset preparation path does beyond reading document sizes. Profile a run over a few bin files to find where the 6.5 minutes go, since the issue's own baseline is about 13 seconds. Done means a measured explanation of the gap or a concrete change with timings, agreed with maintainers first.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
🎯 Description
With 1,250 bin files, dataset preparation takes around 6.5 minutes on 100 cores, 1TB RAM, and 8 GPUs.
However, if I simply iterate through these files, read document sizes, and write them to another file to simulate basic indexing, it takes only about 13 seconds on 12 processes (to match the scenario above, with 100/8 processes per GPU).
from fast_llm.data.dataset.gpt.memmap import GPTMemmapDataset
import numpy as np
import time
import yaml
import multiprocessing as mp
def count_tokens_save_doc_sizes(file, out_file):
ds = GPTMemmapDataset("ds", file)
sizes = ds.get_document_sizes().astype(np.int64)
sizes.tofile(out_file)
return np.sum(sizes)
if __name__ == "__main__":
with open("/mnt/datasets/test/denis/fineweb_the_stack_3b.yaml", "rt") as f:
data = yaml.safe_load(f)
files = [el["path"] for el in data["datasets"][0]["datasets"]] + [
el["path"] for el in data["datasets"][1]["datasets"]
]
t0 = time.time()
with mp.Pool(processes=12) as pool:
ttl = sum(
pool.starmap(
count_tokens_save_doc_sizes,
[(file, f"/mnt/datasets/test/denis/{i}.np") for i, file in enumerate(files)],
)
)
print(f"time {time.time()-t0}")
print(len(files), ttl)
So, I wonder—can we further increase the dataset preparation speed?
- Ngôn ngữ chính
- Python
- Star
- 337
- Fork
- 52
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của ServiceNow/Fast-LLM
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 25/100
ServiceNow/Fast-LLM#556 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 30/100
ServiceNow/Fast-LLM#538 ·
-
enhancement
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 12/100
ServiceNow/Fast-LLM#533 ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 15/100
ServiceNow/Fast-LLM#510 · 1 bình luận ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 12/100
ServiceNow/Fast-LLM#507 ·
Tất cả issue của ServiceNow/Fast-LLM
Issue tương tự
-
[Bug]: Responses API 500s on assistant message with empty content listCó thể đã có người làm @shadowmodder đã nhận hôm nay. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
vllm-project/vllm#64940 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
limits
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Keybind quest outdatedĐang mởStatus: Triage Type: Quest
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
GTNewHorizons/GT-New-Horizons-Modpack#27490 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
LLM.save() discards the model's active prompt styleCó thể đã có người làm @remote-controlled-man đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Lightning-AI/litgpt#2378 ·
Maintainer thường phản hồi trong vòng 23 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
Maintainer thường phản hồi trong vòng 1 ngày