<commit_before>import os
import numpy as np
from likelihood_class import likelihood

class gunn_peterson(likelihood_prior):
  
  def loglkl(self,_cosmo,data):

    xHI_reio = 1.-_cosmo._ionization_fraction(self.z_reio)
    xHI_noreio = 1.-_cosmo._ionization_fraction(self.z_noreio)

    lkl=0

    if (xHI_reio>gunn_peterson.xHI_max) lkl=1.e10
    if (xHI_noreio<gunn_peterson.xHI_min) lkl=1.e10

    print "at z=5.5:"xHI_reio,", at z=6:",xHI_reio,lkl

    return lkl
<commit_msg>added correct gunn_peterson likelihood<commit_after>import os
import numpy as np
from likelihood_class import likelihood

class gunn_peterson(likelihood_prior):
  
  def loglkl(self,_cosmo,data):

    xHI_reio = 1.-_cosmo._ionization_fraction(self.z_reio)
    xHI_noreio = 1.-_cosmo._ionization_fraction(self.z_noreio)

    lkl=0

    if (xHI_reio>gunn_peterson.xHI_max):
      lkl=1.e10
    if (xHI_noreio<gunn_peterson.xHI_min):
      lkl=1.e10

    print "at z=5.5:"xHI_reio,", at z=6:",xHI_reio,lkl

    return lkl

{'fraction_non_alphanumeric': 0.1041041041041041, 'fraction_numerical': 0.024024024024024024, 'mean_word_length': 4.319148936170213, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '812751', 'n_tokens_mistral': 448, 'n_tokens_neox': 420, 'n_words': 67}