Depends on what you want to cook. If you make brownies, check the recipe to see how much it'll make. Lets say you find a recipe that makes 12. Take your weed and multiply by 12. You said it takes you 1/2 gram of weed to get baked. So cook with 6 grams of weed and you'll be fine. You can add more if you want, but baking too much can waste your weed.

RULE OF THUMB: The amount of weed it takes to get you blazed multiplied by the number of servings the recipe makes.