Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions ML/BIT/pdf_bit_training.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@

from pdf.PDFParametrization import PDFParametrization

# Always NUMBA
import numba as nb
from ML.BIT.NumbaBIT import MultiBoostedInformationTree
import ML.BIT.NumbaMultiNode as NumbaMultiNode

from tqdm import trange, tqdm

Expand All @@ -31,11 +27,22 @@
p.add_argument("--postfix", default=None, help="Plot postfix")
p.add_argument("--overwrite", action="store_true", help="Overwrite model file?")
p.add_argument("--small", action="store_true", help="Only first shard for debugging")
p.add_argument("--old", action="store_true", help="No claude improvements.")
p.add_argument("--max_n_files", action="store",type=int, default=None, help="Only this numbe of files.")
p.add_argument("--profile", action="store_true", help="Do CPU profiling?")
p.add_argument("--every", default=5, type=int, help="When to plot (plot if tree_index % every == 0). Set <=0 to disable.")
args = p.parse_args()


# Always NUMBA
import numba as nb
if args.old:
from ML.BIT.oldNumbaBIT import MultiBoostedInformationTree
import ML.BIT.oldNumbaMultiNode as NumbaMultiNode
else:
from ML.BIT.NumbaBIT import MultiBoostedInformationTree
import ML.BIT.NumbaMultiNode as NumbaMultiNode

# ---------------- cfg ----------------
cfg_path = os.path.expanduser(os.path.expandvars(args.config))
CFG = yaml_loader.load_yaml(cfg_path)
Expand Down
2 changes: 1 addition & 1 deletion configs/benchmark/unbinned_delphes_6_RunII.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:
pdf_type: PODBasis
pdf_basis: gluon_POD_nongluon_PDF4LHC21
model:
n_trees: 5
n_trees: 20
learning_rate: 0.2
loss: MSE # or "CrossEntropy"
learn_global_score: true
Expand Down
Loading