I must respectfully disagree with SuperBiasedMan's recommendation for using a dictionary: while it is already a much better solution than yours, that solution is still making things too complicated.
Instead, I recommend using this:

Above is a chart for converting units within the metric system. And, thanks to a quick google search, a good way to remember this would be to remember the phrase:
King Henry doesn't usually drink chocolate milk.
I have bold-ed the first letter of every word to show the correlation between this and the metric system: the first letter of each word directly corresponds to a metric unit "type": kilo*, hecto*, etc.
And, again going back to the chart, we can see that there are numbers associated with each unit "type" to show how many of the basic unit is in one of that unit type.
For example, there are 10 basic units in a deka*, and 0.01 basic units in a centi*.
Now with that information be said, we can easily create a map/different of the different metric "types" and the number of basic units on one of this type.
That would look like this:
types = {
"k": 1000,
"h": 100,
"da": 10,
"": 1,
...
}
To find out what values the user would like, we simply can use the types
dictionary and the user input as an indexer to search the dictionary for what values to add.
That would look like this:
values[input]
Now, for the converting. This process will be very easy since we already have a handy dandy dictionary that holds all the information we need for converting.
All we need to do is divide the amount of basic units of the first type by the amount of basic units for the second type, and then multiply the input number by that result.
Here is what that would look like:
def convert(from_unit_type, to_unit_type, value):
from_type_units = types[from_unit_type]
to_type_units = types[to_unit_type]
new_value = value * (from_type_units / to_type_units)
return str(new_value) + to_unit_type
Using this method, we were able to completely reduce all conditionals.
Putting it all together:
import math
import time
"""Unit Converter"""
#Welcome and variable setting
types = {
"k": 1000,
"h": 100,
"da": 10,
"": 1,
"d": 0.1,
"c": 0.01,
"m": 0.001
}
def convert(from_unit_type, to_unit_type, value):
from_type_units = types[from_unit_type]
to_type_units = types[to_unit_type]
new_value = value * (from_type_units / to_type_units)
return str(new_value) + to_unit_type
print ("Welcome to Sam's Unit Converter")
cat = raw_input ("Which category would you like to convert? [g,l,m]")
unit1 = raw_input ("Which unit would you like to convert from: ")
unit2 = raw_input ("Which unit would you like to convert to: ")
num1 = raw_input ("Enter your value: " )
print(convert(unit1, unit2, float(num1)))
If you have an issues or questions, please let me know in a comment.