This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
from xgboost import XGBModel | |
def dump_xgbmodel(xgb_model: XGBModel) -> dict: | |
""" | |
Dump XGBModel instance as a Solr LTR MultipleAdditiveTreesModel model. | |
Solr LTR MART model specification: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from __future__ import print_function | |
import os | |
import gc | |
from time import sleep | |
import keras.backend as K | |
import numpy as np | |
import psutil | |
from keras.models import Sequential |