hfai ===== 幻方萤火深度学习套件 ``hfai`` 提供了 **训练加速** 、 **环境管理** 与 **萤火调度** 三类核心接口与命令行工具,以此加速用户本地的训练,打通用户个人主机与萤火二号集群。 .. toctree:: :maxdepth: 2 :caption: Contents: hfai.nn ---------------------- .. py:currentmodule:: hfai.nn .. autosummary:: :nosignatures: to_hfai to_torch bench compare LSTM LSTM_fullc GRU LayerNorm MultiheadAttention Dropout Hardtanh LogSoftmax Softmax Softmax2d Softmin Softplus ReLU ReLU6 Threshold LeakyReLU RReLU Hardsigmoid Hardshrink Softshrink hfai.nn.functional ------------------------ .. py:currentmodule:: hfai.nn.functional .. autosummary:: :nosignatures: set_replace_torch dropout hardtanh hardtanh_ log_softmax softmax softmin softplus sync relu relu_ relu6 threshold threshold_ leaky_relu leaky_relu_ rrelu rrelu_ hardsigmoid hardshrink softshrink abs abs_ minimum maximum min max clip clip_ clamp clamp_ clamp_max clamp_max_ clamp_min clamp_min_ where masked_fill masked_fill_ masked_select masked_scatter masked_scatter_ scan associative_scan hfai.datasets -------------------------- .. py:currentmodule:: hfai.datasets .. autosummary:: :nosignatures: BaseDataset set_data_dir get_data_dir download ADE20k AlphafoldData CIFAR10 CIFAR100 CLUEForCLS CLUEForMLM CocoCaption CocoDetection CocoKeypoint CocoPanoptic ERA5 GoogleConceptualCaption ImageNet ImageNet21K ImageNet1K ISC2021 KITTIObject2D LJSpeech LTSF NuScenes OGB WeatherBench hfai.distributed ------------------- .. py:currentmodule:: hfai.distributed .. autosummary:: :nosignatures: init_process_group barrier gather broadcast all_gather reduce_scatter set_nccl_opt_level pairwise_apply hfai.multiprocessing ------------------------ .. py:currentmodule:: hfai.multiprocessing .. autosummary:: :nosignatures: Process spawn fork hfai.checkpoint ------------------ .. py:currentmodule:: hfai.checkpoint .. autosummary:: :nosignatures: init load save hfai.cuda ------------ .. py:currentmodule:: hfai.cuda .. autosummary:: :nosignatures: pin_memory unpin_memory hfai.utils ------------- .. py:currentmodule:: hfai.utils .. autosummary:: :nosignatures: which_numa num_gpus profile_memory bind_numa get_current_numa timeout hfai.utils.{mm, detr2} ----------------------------- .. py:currentmodule:: hfai.utils .. autosummary:: :nosignatures: mm.FFRecordClient detr2.register_ffrecord_handler hfai.autotune ------------- .. py:currentmodule:: hfai.autotune .. autosummary:: :nosignatures: run run_grid_search get_args report show_result set_debug_mode hfai.pl ------------- .. py:currentmodule:: hfai.pl .. autosummary:: :nosignatures: ModelCheckpointHF HFAIEnvironment DDPStrategyBindNuma DDPSpawnStrategyBindNuma HFReduceStrategyBindNuma HFReduceSpawnStrategyBindNuma nn_to_hfai hfai.file ------------ .. py:currentmodule:: hfai.file .. autosummary:: :nosignatures: read_file read_file_as_bytesio hfai.client ---------------- .. py:currentmodule:: hfai.client .. autosummary:: :nosignatures: set_watchdog_time set_whole_life_state get_whole_life_state receive_suspend_command go_suspend EXP_PRIORITY set_priority create_experiment_v2 bind_hf_except_hook get_experiment get_experiments self_health_check .. py:currentmodule:: hfai.client.api .. autosummary:: :nosignatures: Experiment hfai.client.remote -------------------- .. py:currentmodule:: hfai.client.remote .. autosummary:: :nosignatures: GlobalSession SessionConfig