Skip to content

Instantly share code, notes, and snippets.

View king-menin's full-sized avatar
😷
coming from exo

Anton Emelyanov king-menin

😷
coming from exo
View GitHub Profile
// bindary search : sem 2
//
#include <iostream>
#include <vector>
#include <numeric>
int BinarySearch(const std::vector<int> &values, size_t startIndex, size_t endIndex, const int& value) {
size_t midIndex = (startIndex + endIndex) / 2;
// structures.cpp : sem 2
//
#include <iostream>
#include <string>
#include <algorithm>
#include <vector>
// �������� ��������� 1
struct Student {
@king-menin
king-menin / chunks.py
Created January 12, 2023 13:20
Chunks for Alenush
from transformers import AutoTokenizer
from razdel import sentenize
from typing import List
def sent_split(sent):
return sent.split()
def separate_big_sent_by_spaces(whole_text: str, tokenizer, limit_length: int = 512, sent_split=sent_split) -> List[str]: