{"id":8500,"date":"2023-12-20T06:00:28","date_gmt":"2023-12-20T14:00:28","guid":{"rendered":"https:\/\/live-cometml.pantheonsite.io\/?p=8500"},"modified":"2025-04-24T17:03:44","modified_gmt":"2025-04-24T17:03:44","slug":"how-to-use-comet-at-different-stages-of-ml-projects","status":"publish","type":"post","link":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects\/","title":{"rendered":"How To Use Comet At Different Stages of ML Projects"},"content":{"rendered":"\n<div class=\"fk fl fm fn fo\">\n<div class=\"ab ca\">\n<div class=\"ch bg ew ex ey ez\">\n<figure class=\"mb mc md me mf mg ly lz paragraph-image\">\n<div class=\"mh mi ee mj bg mk\" tabindex=\"0\" role=\"button\">\n<figure><img loading=\"lazy\" decoding=\"async\" class=\"bg lf ml c alignnone\" role=\"presentation\" src=\"https:\/\/miro.medium.com\/v2\/resize:fit:700\/0*YD1X4XkqID2CVSJJ\" alt=\"person with a backpack sitting on a mountain looking over trees\" width=\"700\" height=\"467\"><\/figure><div class=\"ly lz ma\"><picture><\/picture><\/div>\n<\/div><figcaption class=\"mm mn mo ly lz mp mq be b bf z dw\" data-selectable-paragraph=\"\">Photo by <a class=\"af mr\" href=\"https:\/\/unsplash.com\/@anhnquyen?utm_source=medium&amp;utm_medium=referral\" target=\"_blank\" rel=\"noopener ugc nofollow\">Nguyen Le Viet Anh<\/a> on <a class=\"af mr\" href=\"https:\/\/unsplash.com\/?utm_source=medium&amp;utm_medium=referral\" target=\"_blank\" rel=\"noopener ugc nofollow\">Unsplash<\/a><\/figcaption><\/figure>\n<p data-selectable-paragraph=\"\">\n<\/p><p id=\"9264\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Machine learning (ML) projects are usually complicated and include several stages, from data discovery to model implementation. The ability to track, compare, and optimize experiments and models is crucial for achieving good outcomes from ML models.<\/p>\n<p id=\"2cfc\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Comet is a robust platform that provides comprehensive functionality to streamline these stages. It helps to manage your models during experimentation and monitor them in a production environment. This article will dive into steps to see how you can use Comet at different stages of ML projects.<\/p>\n<p id=\"abee\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">An ML project majorly includes five big stages:<\/p>\n<ol class=\"\">\n<li id=\"0311\" class=\"ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn no np nq bj\" data-selectable-paragraph=\"\">Data Exploration<\/li>\n<li id=\"c2be\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn no np nq bj\" data-selectable-paragraph=\"\">Model Development<\/li>\n<li id=\"0a40\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn no np nq bj\" data-selectable-paragraph=\"\">Model Optimation<\/li>\n<li id=\"f9fa\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn no np nq bj\" data-selectable-paragraph=\"\">Model Deployment<\/li>\n<li id=\"5b8e\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn no np nq bj\" data-selectable-paragraph=\"\">Collaboration and Documentation<\/li>\n<\/ol>\n<\/div>\n<\/div>\n<\/div>\n\n\n\n<div class=\"ab ca nw nx ny nz\" role=\"separator\"><\/div>\n\n\n\n<div class=\"fk fl fm fn fo\">\n<div class=\"ab ca\">\n<div class=\"ch bg ew ex ey ez\">\n<p id=\"7739\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Before jumping into anything, if you don&#8217;t have Comet in your environment, you can install it using the following command.<\/p>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"cf85\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\">pip install comet_ml<\/span><\/pre>\n<p id=\"dfac\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Once you finish the installation, head to <a class=\"af mr\" href=\"https:\/\/www.comet.com\/\" target=\"_blank\" rel=\"noopener ugc nofollow\"><strong class=\"mu fs\"><em class=\"oo\">comet.com<\/em><\/strong><\/a> and create an account for free.<\/p>\n<p id=\"d081\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">In the top right corner, click on your profile, head to Account Settings, and click on <a class=\"af mr\" href=\"https:\/\/www.comet.com\/account-settings\/apiKeys\" target=\"_blank\" rel=\"noopener ugc nofollow\">API Keys<\/a>. Copy your API key and save it somewhere safe.<\/p>\n<figure class=\"mb mc md me mf mg ly lz paragraph-image\">\n<div class=\"mh mi ee mj bg mk\" tabindex=\"0\" role=\"button\">\n<figure><img decoding=\"async\" class=\"bg lf ml c alignnone\" role=\"presentation\" src=\"https:\/\/miro.medium.com\/v2\/resize:fit:700\/1*6b0m0s4ekBez6UFqROmgRA.png\" alt=\"Author CometML Account Settings > API Keys Screenshot\n&#8221; width=&#8221;700&#8243; height=&#8221;363&#8243;><\/figure><div class=\"ly lz op\"><picture><source srcset=\"https:\/\/miro.medium.com\/v2\/resize:fit:640\/format:webp\/1*6b0m0s4ekBez6UFqROmgRA.png 640w, https:\/\/miro.medium.com\/v2\/resize:fit:720\/format:webp\/1*6b0m0s4ekBez6UFqROmgRA.png 720w, https:\/\/miro.medium.com\/v2\/resize:fit:750\/format:webp\/1*6b0m0s4ekBez6UFqROmgRA.png 750w, https:\/\/miro.medium.com\/v2\/resize:fit:786\/format:webp\/1*6b0m0s4ekBez6UFqROmgRA.png 786w, https:\/\/miro.medium.com\/v2\/resize:fit:828\/format:webp\/1*6b0m0s4ekBez6UFqROmgRA.png 828w, https:\/\/miro.medium.com\/v2\/resize:fit:1100\/format:webp\/1*6b0m0s4ekBez6UFqROmgRA.png 1100w, https:\/\/miro.medium.com\/v2\/resize:fit:1400\/format:webp\/1*6b0m0s4ekBez6UFqROmgRA.png 1400w\" type=\"image\/webp\" sizes=\"(min-resolution: 4dppx) and (max-width: 700px) 50vw, (-webkit-min-device-pixel-ratio: 4) and (max-width: 700px) 50vw, (min-resolution: 3dppx) and (max-width: 700px) 67vw, (-webkit-min-device-pixel-ratio: 3) and (max-width: 700px) 65vw, (min-resolution: 2.5dppx) and (max-width: 700px) 80vw, (-webkit-min-device-pixel-ratio: 2.5) and (max-width: 700px) 80vw, (min-resolution: 2dppx) and (max-width: 700px) 100vw, (-webkit-min-device-pixel-ratio: 2) and (max-width: 700px) 100vw, 700px\"><source srcset=\"https:\/\/miro.medium.com\/v2\/resize:fit:640\/1*6b0m0s4ekBez6UFqROmgRA.png 640w, https:\/\/miro.medium.com\/v2\/resize:fit:720\/1*6b0m0s4ekBez6UFqROmgRA.png 720w, https:\/\/miro.medium.com\/v2\/resize:fit:750\/1*6b0m0s4ekBez6UFqROmgRA.png 750w, https:\/\/miro.medium.com\/v2\/resize:fit:786\/1*6b0m0s4ekBez6UFqROmgRA.png 786w, https:\/\/miro.medium.com\/v2\/resize:fit:828\/1*6b0m0s4ekBez6UFqROmgRA.png 828w, https:\/\/miro.medium.com\/v2\/resize:fit:1100\/1*6b0m0s4ekBez6UFqROmgRA.png 1100w, https:\/\/miro.medium.com\/v2\/resize:fit:1400\/1*6b0m0s4ekBez6UFqROmgRA.png 1400w\" sizes=\"(min-resolution: 4dppx) and (max-width: 700px) 50vw, (-webkit-min-device-pixel-ratio: 4) and (max-width: 700px) 50vw, (min-resolution: 3dppx) and (max-width: 700px) 67vw, (-webkit-min-device-pixel-ratio: 3) and (max-width: 700px) 65vw, (min-resolution: 2.5dppx) and (max-width: 700px) 80vw, (-webkit-min-device-pixel-ratio: 2.5) and (max-width: 700px) 80vw, (min-resolution: 2dppx) and (max-width: 700px) 100vw, (-webkit-min-device-pixel-ratio: 2) and (max-width: 700px) 100vw, 700px\" data-testid=\"og\"><\/picture><\/div>\n<\/div>\n<figcaption class=\"mm mn mo ly lz mp mq be b bf z dw\" data-selectable-paragraph=\"\">Author CometML Account Settings &gt; API Keys Screenshot<\/figcaption>\n<\/figure>\n<p data-selectable-paragraph=\"\">\n<\/p><p id=\"30cb\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Let&#8217;s initialize our Comet experiment and move further in the article.<\/p>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"b44d\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">from<\/span> comet_ml <span class=\"hljs-keyword\">import<\/span> Experiment\nexperiment = Experiment(\n              api_key=<span class=\"hljs-string\">\"Your Secrect API key\"<\/span>,\n              project_name=<span class=\"hljs-string\">\"project name\"<\/span>,\n              workspace=<span class=\"hljs-string\">\"work_space name\"<\/span>\n            )<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n\n\n\n<div class=\"fk fl fm fn fo\">\n<div class=\"ab ca\">\n<div class=\"ch bg ew ex ey ez\">\n<h2 id=\"90de\" class=\"oq oj fr be or os ot gr ou ov ow gu ox oy oz pa pb pc pd pe pf pg ph pi pj pk bj\">1. Data Exploration Using Comet<\/h2>\n<p id=\"d110\" class=\"pw-post-body-paragraph ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn fk bj\" data-selectable-paragraph=\"\">Data Exploration is one of the initial steps of any ML project, as it helps you gain more insight into your data and its characteristics and hidden patterns. Data Exploration also enables you to make better decisions during subsequent stages of the project. Comet provides different methods to facilitate the process of data exploration.<\/p>\n<h2 id=\"7f77\" class=\"pq oj fr be or pr ps pt ou pu pv pw ox nb px py pz nf qa qb qc nj qd qe qf qg bj\" data-selectable-paragraph=\"\">Logging Dataset Statistics<\/h2>\n<ul class=\"\">\n<li id=\"c3d2\" class=\"ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">It&#8217;s essential to understand the data you are working with comprehensively. Comet provides a set of functionalities that allow you to log crucial statistics about your dataset, such as the number of samples, the distribution of values, or the relationships between features.<\/li>\n<li id=\"3168\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">You can use <code class=\"cw qi qj qk of b\">log_dataset_has()<\/code> function to log the hash of your dataset. It will help you track changes in the dataset and determine whether your training runs use the same training data for each epoch.<\/li>\n<\/ul>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"7f97\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">import<\/span> comet_ml\n\n<span class=\"hljs-comment\"># Initialize a CometML experiment<\/span>\nexperiment = comet_ml.Experiment(project_name=<span class=\"hljs-string\">\"data-exploration\"<\/span>, workspace=<span class=\"hljs-string\">\"your-workspace\"<\/span>)\n\n<span class=\"hljs-comment\"># Log dataset statistics<\/span>\nexperiment.log_dataset_hash(path=<span class=\"hljs-string\">\"path\/to\/dataset\"<\/span>)<\/span><\/pre>\n<h2 id=\"5a1d\" class=\"pq oj fr be or pr ps pt ou pu pv pw ox nb px py pz nf qa qb qc nj qd qe qf qg bj\" data-selectable-paragraph=\"\">Tracking Data Distribution<\/h2>\n<ul class=\"\">\n<li id=\"c0c1\" class=\"ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">A good understanding of data is crucial for feature engineering and model selection.<\/li>\n<li id=\"1084\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">Comet has a set of functions that help you visualize the distribution of different features and variables in your dataset.<\/li>\n<\/ul>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"b1a4\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">import<\/span> comet_ml\n<span class=\"hljs-keyword\">import<\/span> matplotlib.pyplot <span class=\"hljs-keyword\">as<\/span> plt\n<span class=\"hljs-keyword\">import<\/span> numpy <span class=\"hljs-keyword\">as<\/span> np\n\n<span class=\"hljs-comment\"># Initialize a CometML experiment<\/span>\nexperiment = comet_ml.Experiment(project_name=<span class=\"hljs-string\">\"data-exploration\"<\/span>, workspace=<span class=\"hljs-string\">\"your-workspace\"<\/span>)\n\n<span class=\"hljs-comment\"># Simulated data<\/span>\ndata = np.random.normal(loc=<span class=\"hljs-number\">0<\/span>, scale=<span class=\"hljs-number\">1<\/span>, size=<span class=\"hljs-number\">1000<\/span>)\n\n<span class=\"hljs-comment\"># Log and visualize data distribution<\/span>\nexperiment.log_histogram_3d(data, name=<span class=\"hljs-string\">\"data_distribution\"<\/span>)\nexperiment.display()<\/span><\/pre>\n<p id=\"b5d1\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Also, you can use <code class=\"cw qi qj qk of b\">log_figure()<\/code> for logging matplotlib graphs into Comet. There are some other functions as well that can be helpful for Data Exploration.<\/p>\n<ul class=\"\">\n<li id=\"ac6d\" class=\"ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn qh np nq bj\" data-selectable-paragraph=\"\"><strong class=\"mu fs\">Experiment.log_dataset_info<\/strong>: <em class=\"oo\">Used to log information about your dataset.<\/em><\/li>\n<li id=\"88d9\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn qh np nq bj\" data-selectable-paragraph=\"\"><strong class=\"mu fs\">Experiment.log_dataframe_profile<\/strong>: <em class=\"oo\">Log a Pandas DataFrame profile as an asset. Optionally, we can also log the data frame.<\/em><\/li>\n<li id=\"d13a\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn qh np nq bj\" data-selectable-paragraph=\"\"><strong class=\"mu fs\">Experiment.log_figure<\/strong>: <em class=\"oo\">Logs the global Pyplot figure or the passed one and uploads its SVG version to the backend.<\/em><\/li>\n<\/ul>\n<\/div>\n<\/div>\n<\/div>\n\n\n\n<div class=\"fk fl fm fn fo\">\n<div class=\"ab ca\">\n<div class=\"ch bg ew ex ey ez\">\n<h2 id=\"534e\" class=\"oq oj fr be or os ot gr ou ov ow gu ox oy oz pa pb pc pd pe pf pg ph pi pj pk bj\">2. Model Development Using Comet<\/h2>\n<p id=\"5e4c\" class=\"pw-post-body-paragraph ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn fk bj\" data-selectable-paragraph=\"\">Model development is one of the most crucial stages in ML projects, where you design, train, evaluate, and fine-tune your models. Comet provides different functions that make this whole process much more manageable.<\/p>\n<h2 id=\"1a5a\" class=\"pq oj fr be or pr ps pt ou pu pv pw ox nb px py pz nf qa qb qc nj qd qe qf qg bj\" data-selectable-paragraph=\"\">Experiment Tracking<\/h2>\n<ul class=\"\">\n<li id=\"defd\" class=\"ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">Experiment tracking is the process of saving all experiment-related information that you care about for every experiment you run. It&#8217;s essential for reproducibility, optimization, troubleshooting, and data-driven decision-making.<\/li>\n<li id=\"319e\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">Comet allows you to track and log your experiment info for each iteration by utilizing different methods of <code class=\"cw qi qj qk of b\">Experiment<\/code> class.<\/li>\n<\/ul>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"3a30\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">from<\/span> comet_ml <span class=\"hljs-keyword\">import<\/span> Experiment\n\n<span class=\"hljs-comment\">## Intialize ComeML experiment<\/span>\nexperiment = Experiment(project_name=<span class=\"hljs-string\">\"tracking-info\"<\/span>, workspace=<span class=\"hljs-string\">\"your-workspace\"<\/span>)\n\n<span class=\"hljs-comment\">## Log hyperparameters and configurations<\/span>\nexperiment.log_parameters({<span class=\"hljs-string\">\"learning_rate\"<\/span>: <span class=\"hljs-number\">0.001<\/span>, <span class=\"hljs-string\">\"batch_size\"<\/span>: <span class=\"hljs-number\">32<\/span>})\n\n<span class=\"hljs-comment\">## Log Model Version<\/span>\nexperiment.log_model(<span class=\"hljs-string\">\"my-model\"<\/span>, model_directory=<span class=\"hljs-string\">\"path\/to\/model\"<\/span>)<\/span><\/pre>\n<h2 id=\"29d5\" class=\"pq oj fr be or pr ps pt ou pu pv pw ox nb px py pz nf qa qb qc nj qd qe qf qg bj\" data-selectable-paragraph=\"\">Monitoring Model Metrics<\/h2>\n<ul class=\"\">\n<li id=\"28ef\" class=\"ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">During the machine learning projects&#8217; training and evaluation phase, monitoring model metrics to track performance and make good decisions is essential.<\/li>\n<li id=\"b8cd\" class=\"ms mt fr mu b gp nr mw mx gs ns mz na nb nt nd ne nf nu nh ni nj nv nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">Comet allows you to log different evaluation matrices like accuracy, loss, precision, recall, etc.<\/li>\n<\/ul>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"a4dc\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">import<\/span> comet_ml\n\n<span class=\"hljs-comment\"># Initialize a CometML experiment<\/span>\nexperiment = comet_ml.Experiment(project_name=<span class=\"hljs-string\">\"model-development\"<\/span>, workspace=<span class=\"hljs-string\">\"your-workspace\"<\/span>)\n\n<span class=\"hljs-comment\"># Evaluation metrics<\/span>\naccuracy = ...  <span class=\"hljs-comment\"># Calculate accuracy<\/span>\n\n<span class=\"hljs-comment\"># Log metrics<\/span>\nexperiment.log_metric(<span class=\"hljs-string\">\"accuracy\"<\/span>, accuracy)<\/span><\/pre>\n<p id=\"b0f2\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">There are many other functions that you can use to monitor different components of machine learning model development. You can find them <a class=\"af mr\" href=\"https:\/\/www.comet.com\/docs\/python-sdk\/Experiment\/\" target=\"_blank\" rel=\"noopener ugc nofollow\">here<\/a>.<\/p>\n<\/div>\n<\/div>\n<\/div>\n\n\n\n<div class=\"fk fl fm fn fo\">\n<div class=\"ab ca\">\n<div class=\"ch bg ew ex ey ez\">\n<h2 id=\"2dad\" class=\"oq oj fr be or os ot gr ou ov ow gu ox oy oz pa pb pc pd pe pf pg ph pi pj pk bj\">3. Model Optimization<\/h2>\n<p id=\"14aa\" class=\"pw-post-body-paragraph ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn fk bj\" data-selectable-paragraph=\"\">Model optimization helps improve the performance and efficiency of your model by tuning hyperparameters. Comet provides:<\/p>\n<h2 id=\"efe0\" class=\"pq oj fr be or pr ps pt ou pu pv pw ox nb px py pz nf qa qb qc nj qd qe qf qg bj\" data-selectable-paragraph=\"\">Hyperparameter Tuning<\/h2>\n<ul class=\"\">\n<li id=\"c57b\" class=\"ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">A hyperparameter is a parameter whose value controls the learning process. Hyperparameter tuning means finding a set of optimal parameters for your model.<\/li>\n<\/ul>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"02c4\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">import<\/span> comet_ml\n<span class=\"hljs-keyword\">from<\/span> sklearn.model_selection <span class=\"hljs-keyword\">import<\/span> GridSearchCV\n<span class=\"hljs-keyword\">from<\/span> sklearn <span class=\"hljs-keyword\">import<\/span> tree\n<span class=\"hljs-keyword\">from<\/span> sklearn.datasets <span class=\"hljs-keyword\">import<\/span> load_iris\n<span class=\"hljs-keyword\">from<\/span> sklearn.model_selection <span class=\"hljs-keyword\">import<\/span> train_test_split\n\n<span class=\"hljs-comment\"># Load the dataset<\/span>\nX, y = load_iris(return_X_y=<span class=\"hljs-literal\">True<\/span>)\nX_train, X_test, y_train, y_test = train_test_split(X, y, test_size=<span class=\"hljs-number\">0.2<\/span>, random_state=<span class=\"hljs-number\">42<\/span>)\n\n<span class=\"hljs-comment\"># Initialize a CometML experiment<\/span>\nexperiment = comet_ml.Experiment(project_name=<span class=\"hljs-string\">\"hyperparameter-optimization\"<\/span>, workspace=<span class=\"hljs-string\">\"your-workspace\"<\/span>)\n\n<span class=\"hljs-comment\"># Define the search space for hyperparameters<\/span>\nparam_grid = {\n    <span class=\"hljs-string\">\"C\"<\/span>: [<span class=\"hljs-number\">0.1<\/span>, <span class=\"hljs-number\">1.0<\/span>, <span class=\"hljs-number\">10.0<\/span>],\n    <span class=\"hljs-string\">\"gamma\"<\/span>: [<span class=\"hljs-number\">0.001<\/span>, <span class=\"hljs-number\">0.01<\/span>, <span class=\"hljs-number\">0.1<\/span>],\n    <span class=\"hljs-string\">\"kernel\"<\/span>: [<span class=\"hljs-string\">\"linear\"<\/span>, <span class=\"hljs-string\">\"rbf\"<\/span>]\n}\n\n<span class=\"hljs-comment\">## Log Param Grid<\/span>\nexperiment.log_parameters(param_grid)\n\n<span class=\"hljs-comment\"># Initialize the model with default hyperparameters<\/span>\nmodel = tree.DecisionTreeClassifier()\n\n<span class=\"hljs-comment\"># Perform hyperparameter optimization<\/span>\noptimizer = GridSearchCV(model, param_grid, cv=<span class=\"hljs-number\">3<\/span>, n_jobs=-<span class=\"hljs-number\">1<\/span>)\noptimizer.fit(X_train, y_train)\n\n<span class=\"hljs-comment\"># Log the best hyperparameters and evaluation metric<\/span>\nbest_params = optimizer.best_params_\nbest_score = optimizer.best_score_\n\n<span class=\"hljs-comment\"># Log best params and best score<\/span>\nexperiment.log_parameters(best_params)\nexperiment.log_metric(<span class=\"hljs-string\">\"accuracy\"<\/span>, best_score)<\/span><\/pre>\n<h2 id=\"d8ca\" class=\"pq oj fr be or pr ps pt ou pu pv pw ox nb px py pz nf qa qb qc nj qd qe qf qg bj\" data-selectable-paragraph=\"\">Compare Model Architecture<\/h2>\n<ul class=\"\">\n<li id=\"9df5\" class=\"ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn qh np nq bj\" data-selectable-paragraph=\"\">Comet makes it easy to keep a record and monitor various model architectures as you fine-tune them, enabling you to discover the most impactful design. By experimenting with different combinations of hyperparameters in neural networks, you can determine the optimal configuration that yields the greatest accuracy and performance. This exploration process becomes more efficient with Comet&#8217;s tracking capabilities.<\/li>\n<\/ul>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"f047\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">import<\/span> comet_ml\n<span class=\"hljs-keyword\">from<\/span> tensorflow <span class=\"hljs-keyword\">import<\/span> keras\n<span class=\"hljs-keyword\">from<\/span> sklearn.model_selection <span class=\"hljs-keyword\">import<\/span> train_test_split\n<span class=\"hljs-keyword\">from<\/span> sklearn.metrics <span class=\"hljs-keyword\">import<\/span> accuracy_score\n<span class=\"hljs-keyword\">import<\/span> numpy <span class=\"hljs-keyword\">as<\/span> np\n\n<span class=\"hljs-comment\"># Load and preprocess the dataset<\/span>\nX, y = load_dataset()  <span class=\"hljs-comment\">## Custom functionf for loading dataset<\/span>\nX_train, X_test, y_train, y_test = train_test_split(X, y, test_size=<span class=\"hljs-number\">0.2<\/span>)\n\n<span class=\"hljs-comment\"># Initialize a CometML experiment<\/span>\nexperiment = comet_ml.Experiment(project_name=<span class=\"hljs-string\">\"model-architecture-search\"<\/span>, workspace=<span class=\"hljs-string\">\"your-workspace\"<\/span>)\n\n<span class=\"hljs-comment\"># Define the model architecture search space<\/span>\nmodel_architectures = [\n    {<span class=\"hljs-string\">\"layers\"<\/span>: [<span class=\"hljs-number\">64<\/span>, <span class=\"hljs-number\">32<\/span>], <span class=\"hljs-string\">\"activation\"<\/span>: <span class=\"hljs-string\">\"relu\"<\/span>},\n    {<span class=\"hljs-string\">\"layers\"<\/span>: [<span class=\"hljs-number\">128<\/span>, <span class=\"hljs-number\">64<\/span>, <span class=\"hljs-number\">32<\/span>], <span class=\"hljs-string\">\"activation\"<\/span>: <span class=\"hljs-string\">\"relu\"<\/span>},\n    {<span class=\"hljs-string\">\"layers\"<\/span>: [<span class=\"hljs-number\">32<\/span>, <span class=\"hljs-number\">16<\/span>], <span class=\"hljs-string\">\"activation\"<\/span>: <span class=\"hljs-string\">\"sigmoid\"<\/span>},\n    {<span class=\"hljs-string\">\"layers\"<\/span>: [<span class=\"hljs-number\">128<\/span>, <span class=\"hljs-number\">64<\/span>, <span class=\"hljs-number\">32<\/span>, <span class=\"hljs-number\">16<\/span>], <span class=\"hljs-string\">\"activation\"<\/span> : <span class=\"hljs-string\">\"relu\"<\/span>},\n]\n\n<span class=\"hljs-comment\"># Iterate through the model architectures<\/span>\n<span class=\"hljs-keyword\">for<\/span> architecture <span class=\"hljs-keyword\">in<\/span> model_architectures:\n\n    <span class=\"hljs-comment\"># Initialize the model<\/span>\n    model = keras.Sequential()\n\n    <span class=\"hljs-comment\"># Build the model with the selected architecture<\/span>\n    <span class=\"hljs-keyword\">for<\/span> units <span class=\"hljs-keyword\">in<\/span> architecture[<span class=\"hljs-string\">\"layers\"<\/span>]:\n        model.add(keras.layers.Dense(units, activation=architecture[<span class=\"hljs-string\">\"activation\"<\/span>]))\n\n    <span class=\"hljs-comment\"># Compile the model<\/span>\n    model.<span class=\"hljs-built_in\">compile<\/span>(optimizer=<span class=\"hljs-string\">\"adam\"<\/span>, loss=<span class=\"hljs-string\">\"categorical_crossentropy\"<\/span>, metrics=[<span class=\"hljs-string\">\"accuracy\"<\/span>])\n\n    <span class=\"hljs-comment\"># Train the model<\/span>\n    model.fit(X_train, y_train, epochs=<span class=\"hljs-number\">10<\/span>, batch_size=<span class=\"hljs-number\">32<\/span>, validation_data=(X_test, y_test))\n\n    <span class=\"hljs-comment\"># Evaluate the model<\/span>\n    y_pred = np.argmax(model.predict(X_test), axis=<span class=\"hljs-number\">1<\/span>)\n    accuracy = accuracy_score(y_test, y_pred)\n\n    <span class=\"hljs-comment\"># Log the model architecture and evaluation metric<\/span>\n    experiment.log_parameter(<span class=\"hljs-string\">\"layers\"<\/span>, architecture[<span class=\"hljs-string\">\"layers\"<\/span>])\n    experiment.log_parameter(<span class=\"hljs-string\">\"activation\"<\/span>, architecture[<span class=\"hljs-string\">\"activation\"<\/span>])\n    experiment.log_metric(<span class=\"hljs-string\">\"accuracy\"<\/span>, accuracy)<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n\n\n\n<div class=\"fk fl fm fn fo\">\n<div class=\"ab ca\">\n<div class=\"ch bg ew ex ey ez\">\n<h2 id=\"6fb5\" class=\"oq oj fr be or os ot gr ou ov ow gu ox oy oz pa pb pc pd pe pf pg ph pi pj pk bj\">4. Model Deployment<\/h2>\n<p id=\"b3f5\" class=\"pw-post-body-paragraph ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn fk bj\" data-selectable-paragraph=\"\">Model deployment is a final end-user step where you connect your machine learning models with a web app and make it available for real-world testing.<\/p>\n<p id=\"1369\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">You can use Comet as a database to store all your predictions and user interactions to perform analysis later to improve the algorithm and other aspects of your model.<\/p>\n<p id=\"140a\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Note<em class=\"oo\">: Comet can not be used to deploy a model, however, you can use it as a database to store your predictions and logs. <\/em><\/p>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"1470\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-keyword\">import<\/span> comet_ml\n<span class=\"hljs-keyword\">import<\/span> streamlit <span class=\"hljs-keyword\">as<\/span> st\n<span class=\"hljs-keyword\">import<\/span> joblib\n\n<span class=\"hljs-comment\"># Load the serialized model<\/span>\nmodel = joblib.load(<span class=\"hljs-string\">'path_to_model.joblib'<\/span>)\n\n<span class=\"hljs-comment\"># Initialize a CometML experiment<\/span>\nexperiment = comet_ml.Experiment(project_name=<span class=\"hljs-string\">'model-deployment'<\/span>, workspace=<span class=\"hljs-string\">'your-workspace'<\/span>)\n\n<span class=\"hljs-comment\"># Define the prediction function<\/span>\n<span class=\"hljs-keyword\">def<\/span> <span class=\"hljs-title.function\">predict<\/span>(<span class=\"hljs-params\">data<\/span>):\n    <span class=\"hljs-comment\"># Processing (if necessary)<\/span>\n    preprocessed_data = preprocess(data) <span class=\"hljs-comment\">## preprocess() is a user defined function for processing user input into a proper format<\/span>\n\n    <span class=\"hljs-comment\"># Predictions<\/span>\n    predictions = model.predict(preprocessed_data)\n\n    <span class=\"hljs-comment\"># Log predictions to CometML<\/span>\n    experiment.log_text(predictions)\n\n    <span class=\"hljs-keyword\">return<\/span> predictions\n\n<span class=\"hljs-comment\"># Streamlit app<\/span>\n<span class=\"hljs-keyword\">def<\/span> <span class=\"hljs-title.function\">main<\/span>():\n    st.title(<span class=\"hljs-string\">'Streamlit App'<\/span>)\n    st.write(<span class=\"hljs-string\">'Enter your input below:'<\/span>)\n\n    <span class=\"hljs-comment\"># Form<\/span>\n    input_data = {}\n    <span class=\"hljs-keyword\">for<\/span> feature <span class=\"hljs-keyword\">in<\/span> features:\n        input_data[feature] = st.number_input(<span class=\"hljs-string\">f'Enter <span class=\"hljs-subst\">{feature}<\/span>:'<\/span>)\n\n    <span class=\"hljs-comment\"># Make predictions<\/span>\n    <span class=\"hljs-keyword\">if<\/span> st.button(<span class=\"hljs-string\">'Predict'<\/span>):\n        predictions = predict([<span class=\"hljs-built_in\">list<\/span>(input_data.values())])\n        st.write(<span class=\"hljs-string\">'Predictions:'<\/span>, predictions)\n\n<span class=\"hljs-keyword\">if<\/span> __name__ == <span class=\"hljs-string\">'__main__'<\/span>:\n    main()<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n\n\n\n<div class=\"fk fl fm fn fo\">\n<div class=\"ab ca\">\n<div class=\"ch bg ew ex ey ez\">\n<h2 id=\"51a3\" class=\"oq oj fr be or os ot gr ou ov ow gu ox oy oz pa pb pc pd pe pf pg ph pi pj pk bj\">5. Collaboration and Documentation<\/h2>\n<p id=\"f6fa\" class=\"pw-post-body-paragraph ms mt fr mu b gp pl mw mx gs pm mz na nb pn nd ne nf po nh ni nj pp nl nm nn fk bj\" data-selectable-paragraph=\"\">Collaboration and documentation are essential aspects of ML projects. They enable teams to collaborate on a single project, share their knowledge, reproduce experiments, and ensure project transparency. Comet is built for this, offering many features that facilitate model collaboration and documentation.<\/p>\n<p id=\"2730\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">Comet allows you to share your experiments with team members, which lets them view, comment, and collaborate on your experiments. Comet offers multiple straightforward ways to share experiments:<\/p>\n<p id=\"7319\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">\u25fe<strong class=\"mu fs\">Share Experiment URL<\/strong>: Every experiment in Comet is assigned a unique URL. You can copy the URL and share your team members via email, message, or project management tools. Team members can access the experiment by visiting their browser&#8217;s shared URL.<\/p>\n<p id=\"7dc9\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">\u25fe<strong class=\"mu fs\">Access to Workspace<\/strong>: A Workspace in Comet is a dedicated environment for team collaboration. To invite your team members to your workspace, go to Comet web interface &gt; navigate to the Workspace section and add their email addresses. (<em class=\"oo\">This option is only available for premium members.<\/em>)<\/p>\n<p id=\"f0b3\" class=\"pw-post-body-paragraph ms mt fr mu b gp mv mw mx gs my mz na nb nc nd ne nf ng nh ni nj nk nl nm nn fk bj\" data-selectable-paragraph=\"\">\u25fe<strong class=\"mu fs\">Export and Share<\/strong>: If you want to share your experiment info offline, you can easily export it as a PDF.<\/p>\n<pre class=\"mb mc md me mf oe of og bo oh ba bj\"><span id=\"bd7e\" class=\"oi oj fr of b bf ok ol l om on\" data-selectable-paragraph=\"\"><span class=\"hljs-comment\"># Add experiment description and tags<\/span>\nexperiment.set_name(<span class=\"hljs-string\">'Monkey Breed Classification'<\/span>)\nexperiment.add_tags([<span class=\"hljs-string\">'Monkey Breed Data'<\/span>, <span class=\"hljs-string\">'Transfer Learning'<\/span>])\nexperiment.set_description(<span class=\"hljs-string\">'This experiment classify monkey breeds.'<\/span>)\nexperiment.add_link(<span class=\"hljs-string\">\"Google Drive\"<\/span>, <span class=\"hljs-string\">\"https:\/\/drive.google.com\"<\/span>)\n\n\n<span class=\"hljs-comment\"># Share the experiment link with team members<\/span>\nexperiment_url = experiment.url\n<span class=\"hljs-built_in\">print<\/span>(<span class=\"hljs-string\">f\"Experiment URL: <span class=\"hljs-subst\">{experiment_url}<\/span>\"<\/span>)<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n\n\n\n<div class=\"ab ca nw nx ny nz\" role=\"separator\"><span style=\"font-family: var(--wpex-body-font-family, var(--wpex-font-sans)); font-size: var(--wpex-body-font-size, 13px);\">I&#8217;ve merely scratched the surface of Comet in my explanation and sharing; there&#8217;s so much more to explore, which I&#8217;ll leave in your capable hands.<\/span><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Photo by Nguyen Le Viet Anh on Unsplash Machine learning (ML) projects are usually complicated and include several stages, from data discovery to model implementation. The ability to track, compare, and optimize experiments and models is crucial for achieving good outcomes from ML models. Comet is a robust platform that provides comprehensive functionality to streamline [&hellip;]<\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"customer_name":"","customer_description":"","customer_industry":"","customer_technologies":"","customer_logo":"","footnotes":""},"categories":[9,7],"tags":[],"coauthors":[140],"class_list":["post-8500","post","type-post","status-publish","format-standard","hentry","category-product","category-tutorials"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v25.9 (Yoast SEO v25.9) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How To Use Comet At Different Stages of ML Projects<\/title>\n<meta name=\"description\" content=\"Walk through five steps to learn how you can use Comet at different stages of ML projects. Read more in this tutorial.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How To Use Comet At Different Stages of ML Projects\" \/>\n<meta property=\"og:description\" content=\"Walk through five steps to learn how you can use Comet at different stages of ML projects. Read more in this tutorial.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects\" \/>\n<meta property=\"og:site_name\" content=\"Comet\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/cometdotml\" \/>\n<meta property=\"article:published_time\" content=\"2023-12-20T14:00:28+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-04-24T17:03:44+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/miro.medium.com\/v2\/resize:fit:700\/0*YD1X4XkqID2CVSJJ\" \/>\n<meta name=\"author\" content=\"Abhay Parashar\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@Cometml\" \/>\n<meta name=\"twitter:site\" content=\"@Cometml\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Abhay Parashar\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"How To Use Comet At Different Stages of ML Projects","description":"Walk through five steps to learn how you can use Comet at different stages of ML projects. Read more in this tutorial.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects","og_locale":"en_US","og_type":"article","og_title":"How To Use Comet At Different Stages of ML Projects","og_description":"Walk through five steps to learn how you can use Comet at different stages of ML projects. Read more in this tutorial.","og_url":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects","og_site_name":"Comet","article_publisher":"https:\/\/www.facebook.com\/cometdotml","article_published_time":"2023-12-20T14:00:28+00:00","article_modified_time":"2025-04-24T17:03:44+00:00","og_image":[{"url":"https:\/\/miro.medium.com\/v2\/resize:fit:700\/0*YD1X4XkqID2CVSJJ","type":"","width":"","height":""}],"author":"Abhay Parashar","twitter_card":"summary_large_image","twitter_creator":"@Cometml","twitter_site":"@Cometml","twitter_misc":{"Written by":"Abhay Parashar","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects#article","isPartOf":{"@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects\/"},"author":{"name":"Team Comet Digital","@id":"https:\/\/www.comet.com\/site\/#\/schema\/person\/6266601170c60a7a82b3e0043fbe8ddf"},"headline":"How To Use Comet At Different Stages of ML Projects","datePublished":"2023-12-20T14:00:28+00:00","dateModified":"2025-04-24T17:03:44+00:00","mainEntityOfPage":{"@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects\/"},"wordCount":993,"publisher":{"@id":"https:\/\/www.comet.com\/site\/#organization"},"image":{"@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects#primaryimage"},"thumbnailUrl":"https:\/\/miro.medium.com\/v2\/resize:fit:700\/0*YD1X4XkqID2CVSJJ","articleSection":["Product","Tutorials"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects\/","url":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects","name":"How To Use Comet At Different Stages of ML Projects","isPartOf":{"@id":"https:\/\/www.comet.com\/site\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects#primaryimage"},"image":{"@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects#primaryimage"},"thumbnailUrl":"https:\/\/miro.medium.com\/v2\/resize:fit:700\/0*YD1X4XkqID2CVSJJ","datePublished":"2023-12-20T14:00:28+00:00","dateModified":"2025-04-24T17:03:44+00:00","description":"Walk through five steps to learn how you can use Comet at different stages of ML projects. Read more in this tutorial.","breadcrumb":{"@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects#primaryimage","url":"https:\/\/miro.medium.com\/v2\/resize:fit:700\/0*YD1X4XkqID2CVSJJ","contentUrl":"https:\/\/miro.medium.com\/v2\/resize:fit:700\/0*YD1X4XkqID2CVSJJ"},{"@type":"BreadcrumbList","@id":"https:\/\/www.comet.com\/site\/blog\/how-to-use-comet-at-different-stages-of-ml-projects#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.comet.com\/site\/"},{"@type":"ListItem","position":2,"name":"How To Use Comet At Different Stages of ML Projects"}]},{"@type":"WebSite","@id":"https:\/\/www.comet.com\/site\/#website","url":"https:\/\/www.comet.com\/site\/","name":"Comet","description":"Build Better Models Faster","publisher":{"@id":"https:\/\/www.comet.com\/site\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.comet.com\/site\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.comet.com\/site\/#organization","name":"Comet ML, Inc.","alternateName":"Comet","url":"https:\/\/www.comet.com\/site\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.comet.com\/site\/#\/schema\/logo\/image\/","url":"https:\/\/www.comet.com\/site\/wp-content\/uploads\/2025\/01\/logo_comet_square.png","contentUrl":"https:\/\/www.comet.com\/site\/wp-content\/uploads\/2025\/01\/logo_comet_square.png","width":310,"height":310,"caption":"Comet ML, Inc."},"image":{"@id":"https:\/\/www.comet.com\/site\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/cometdotml","https:\/\/x.com\/Cometml","https:\/\/www.youtube.com\/channel\/UCmN63HKvfXSCS-UwVwmK8Hw"]},{"@type":"Person","@id":"https:\/\/www.comet.com\/site\/#\/schema\/person\/6266601170c60a7a82b3e0043fbe8ddf","name":"Team Comet Digital","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.comet.com\/site\/#\/schema\/person\/image\/4f0c0a8cc7c0e87c636ff6a420a6647c","url":"https:\/\/www.comet.com\/site\/wp-content\/uploads\/2023\/08\/Screen-Shot-2023-08-12-at-8.58.50-AM-96x96.png","contentUrl":"https:\/\/www.comet.com\/site\/wp-content\/uploads\/2023\/08\/Screen-Shot-2023-08-12-at-8.58.50-AM-96x96.png","caption":"Team Comet Digital"},"sameAs":["https:\/\/www.comet.ml\/"],"url":"https:\/\/www.comet.com\/site\/blog\/author\/teamcometdigital\/"}]}},"_links":{"self":[{"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/posts\/8500","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/comments?post=8500"}],"version-history":[{"count":1,"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/posts\/8500\/revisions"}],"predecessor-version":[{"id":15414,"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/posts\/8500\/revisions\/15414"}],"wp:attachment":[{"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/media?parent=8500"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/categories?post=8500"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/tags?post=8500"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/www.comet.com\/site\/wp-json\/wp\/v2\/coauthors?post=8500"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}