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
class SaveModelCallback(TrackerCallback): | |
"A `TrackerCallback` that saves the model's best during training and loads it at the end." | |
order = TrackerCallback.order+1 | |
def __init__(self, monitor='valid_loss', comp=None, min_delta=0., fname='model', every_epoch=False, at_end=False, | |
with_opt=False, reset_on_fit=True): | |
super().__init__(monitor=monitor, comp=comp, min_delta=min_delta, reset_on_fit=reset_on_fit) | |
assert not (every_epoch and at_end), "every_epoch and at_end cannot both be set to True" | |
# keep track of file path for loggers | |
self.last_saved_path = None | |
self.last_saved_metadata = None |
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
class WandbCallback(Callback): | |
"Saves model topology, losses & metrics" | |
remove_on_fetch,order = True,Recorder.order+1 | |
# Record if watch has been called previously (even in another instance) | |
_wandb_watch_called = False | |
def __init__(self, log="gradients", log_preds=True, log_model=True, log_dataset=False, dataset_name=None, valid_dl=None, n_preds=36, seed=12345, reorder=True): | |
# Check if wandb.init has been called | |
if wandb.run is None: | |
raise ValueError('You must call wandb.init() before WandbCallback()') |
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
javascript: ftb(); | |
function getStatus() { | |
$.ajax({ | |
type: "GET", | |
url: "/goform/goform_get_cmd_process", | |
data: { | |
cmd: "lte_pci,lte_pci_lock,lte_earfcn_lock,wan_ipaddr,wan_apn,pm_sensor_mdm,pm_modem_5g,nr5g_pci,nr5g_action_channel,nr5g_action_band,Z5g_SINR,Z5g_rsrp,wan_active_band,wan_active_channel,wan_lte_ca,lte_multi_ca_scell_info,cell_id,dns_mode,prefer_dns_manual,standby_dns_manual,network_type,rmcc,rmnc,lte_rsrq,lte_rssi,lte_rsrp,lte_snr,wan_lte_ca,lte_ca_pcell_band,lte_ca_pcell_bandwidth,lte_ca_scell_band,lte_ca_scell_bandwidth,lte_ca_pcell_arfcn,lte_ca_scell_arfcn,wan_ipaddr,static_wan_ipaddr,opms_wan_mode,opms_wan_auto_mode,ppp_status,loginfo", | |
multi_data: "1", | |
}, | |
dataType: "json", |