(buffer)
| 4762 | } |
| 4763 | } |
| 4764 | XGBoosterLoadModelFromBuffer(buffer) { |
| 4765 | if (buffer.length > 2 && buffer[0] === 0x7B && buffer[1] !== 0x22) { |
| 4766 | const obj = execution.invoke('ubjson.loadb', [buffer]); |
| 4767 | this.XGBoosterLoadModel(obj); |
| 4768 | return; |
| 4769 | } |
| 4770 | throw new python.Error('Unsupported XGBoost binary format.'); |
| 4771 | } |
| 4772 | XGBoosterUnserializeFromBuffer(buffer) { |
| 4773 | if (buffer.length > 2 && buffer[0] === 0x7B && buffer[1] !== 0x22) { |
| 4774 | const obj = execution.invoke('ubjson.loadb', [buffer]); |
no test coverage detected