Buckets:
AnonymousSpottedToad/candidate_bucket / codebase /python /mlco2_codecarbon /examples /logfire_metrics.py
| import time | |
| from codecarbon import track_emissions | |
| def train_model(): | |
| """ | |
| This function will do nothing during (occurrence * delay) seconds. | |
| The Logfire API will be called every (measure_power_secs * api_call_interval) seconds. | |
| """ | |
| occurrence = 60 # seconds | |
| delay = 1 # Seconds | |
| for i in range(occurrence): | |
| print(f"{occurrence * delay - i * delay} seconds before ending script...") | |
| time.sleep(delay) | |
| if __name__ == "__main__": | |
| train_model() | |
Xet Storage Details
- Size:
- 592 Bytes
- Xet hash:
- 9f511fe2794937ef0a65be6e4fbca515d4206d26057e65aef302192640ab5bd7
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.