<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-

import json

def decode(data):
    try:
        #print imgarray[0]
        len1 = int(data[0])
        #print str(len1)
        len2 = int(data[2:(int(data[0]) + 2)])
        #print str(len2) + " \n"
        packetData = data[3 + len1:(3 + len1 + len2)]
        #print packetData
        imgarray = data[(4 + len1 + len2):]
        #print "!!!" + imgarray + "!!!"
        try:
            packetData = json.loads(packetData)

            return {
                'data': packetData,
                'body': imgarray
            }

        except Exception, e:
            pass
    except:<commit_msg>usunięcie komentarzy w decode.py<commit_after>#!/usr/bin/env python
# -*- coding: utf-8 -*-

import json

def decode(data):
    try:
        len1 = int(data[0])
        len2 = int(data[2:(int(data[0]) + 2)])
        packetData = data[3 + len1:(3 + len1 + len2)]
        imgarray = data[(4 + len1 + len2):]
        try:
            packetData = json.loads(packetData)

            return {
                'data': packetData,
                'body': imgarray
            }

        except Exception, e:
            pass
    except:
{'fraction_non_alphanumeric': 0.14597315436241612, 'fraction_numerical': 0.027684563758389263, 'mean_word_length': 1.5766738660907127, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5384323', 'n_tokens_mistral': 400, 'n_tokens_neox': 385, 'n_words': 85}