Package it.unimi.dsi.fastutil.floats

Examples of it.unimi.dsi.fastutil.floats.FloatList


   
    @Override
    public Explanation explain(int doc){
      String[] vals = _array.getTranslatedData(doc, _dataCache.valArray);
     
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      for (String val : vals)
      {
        int idx = _dataCache.valArray.indexOf(val);
        if (idx>=0){
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here


    @Override
    public Explanation explain(int doc){
      int encoded=_dataCache.orderArray.get(doc);
     
      int count=1;
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      while(encoded != 0)
      {
        if ((encoded & 0x00000001) != 0x0){
          int idx = count -1;
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
        count++;
        encoded >>>= 1;
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

   
    @Override
    public Explanation explain(int doc){
      String[] vals = _array.getTranslatedData(doc, _dataCache.valArray);
     
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      for (String val : vals)
      {
        int idx = _dataCache.valArray.indexOf(val);
        if (idx>=0){
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

    @Override
    public Explanation explain(int doc){
      int encoded=_dataCache.orderArray.get(doc);
     
      int count=1;
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      while(encoded != 0)
      {
        if ((encoded & 0x00000001) != 0x0){
          int idx = count -1;
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
        count++;
        encoded >>>= 1;
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

   
    @Override
    public Explanation explain(int doc){
      String[] vals = _array.getTranslatedData(doc, _dataCache.valArray);
     
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      for (String val : vals)
      {
        int idx = _dataCache.valArray.indexOf(val);
        if (idx>=0){
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

    @Override
    public Explanation explain(int doc){
      int encoded=_dataCache.orderArray.get(doc);
     
      int count=1;
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      while(encoded != 0)
      {
        if ((encoded & 0x00000001) != 0x0){
          int idx = count -1;
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
        count++;
        encoded >>>= 1;
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

    @Override
    public Explanation explain(int doc) {
      String[] vals = _array.getTranslatedData(doc, _dataCache.valArray);

      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      for (String val : vals) {
        int idx = _dataCache.valArray.indexOf(val);
        if (idx >= 0) {
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList) {
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

    @Override
    public Explanation explain(int doc) {
      int encoded = _dataCache.orderArray.get(doc);

      int count = 1;
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      while (encoded != 0) {
        if ((encoded & 0x00000001) != 0x0) {
          int idx = count - 1;
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
        count++;
        encoded >>>= 1;
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList) {
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

   
    @Override
    public Explanation explain(int doc){
      String[] vals = _array.getTranslatedData(doc, _dataCache.valArray);
     
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      for (String val : vals)
      {
        int idx = _dataCache.valArray.indexOf(val);
        if (idx>=0){
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

    @Override
    public Explanation explain(int doc){
      int encoded=_dataCache.orderArray.get(doc);
     
      int count=1;
      FloatList scoreList = new FloatArrayList(_dataCache.valArray.size());
      ArrayList<Explanation> explList = new ArrayList<Explanation>(scoreList.size());
      while(encoded != 0)
      {
        if ((encoded & 0x00000001) != 0x0){
          int idx = count -1;
          scoreList.add(_function.score(_dataCache.freqs[idx], _boostList[idx]));
          explList.add(_function.explain(_dataCache.freqs[idx], _boostList[idx]));
        }
        count++;
        encoded >>>= 1;
      }
      Explanation topLevel = _function.explain(scoreList.toFloatArray());
      for (Explanation sub : explList){
        topLevel.addDetail(sub);
      }
      return topLevel;
    }
View Full Code Here

TOP

Related Classes of it.unimi.dsi.fastutil.floats.FloatList

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.