```json
{
  "sym_variables": [
    ("x0", "engineer platoons"),
    ("x1", "transportation companies"),
    ("x2", "military intelligence companies"),
    ("x3", "pathfinder teams")
  ],
  "objective_function": "3*x0 + 6*x1 + 7*x2 + 1*x3",
  "constraints": [
    "4.69*x0 + 1.63*x2 >= 15",
    "4.69*x0 + 2.64*x1 >= 14",
    "2.64*x1 + 1.63*x2 >= 34",
    "1.48*x0 + 1.63*x2 >= 33",
    "3.24*x2 + 2.78*x3 >= 21",
    "1.48*x0 + 0.52*x1 + 2.78*x3 >= 36",
    "0.52*x1 + 3.24*x2 + 2.78*x3 >= 36",
    "1.48*x0 + 0.52*x1 + 2.78*x3 >= 30",
    "0.52*x1 + 3.24*x2 + 2.78*x3 >= 30",
    "3.92*x1 + 3.21*x2 + 4.35*x3 >= 22",
    "0.73*x0 + 2.29*x3 >= 21",
    "0.85*x1 + 0.87*x2 >= 27",
    "0.73*x0 + 0.87*x2 >= 45",
    "0.85*x1 + 2.29*x3 >= 44",
    "0.87*x2 + 2.29*x3 >= 39",
    "4.69*x0 + 4.28*x3 <= 70",
    "4.69*x0 + 1.63*x2 <= 141",
    "1.63*x2 + 4.28*x3 <= 51",
    "2.64*x1 + 1.63*x2 + 4.28*x3 <= 52",
    "4.69*x0 + 1.63*x2 + 4.28*x3 <= 76",
    "4.69*x0 + 2.64*x1 + 4.28*x3 <= 44",
    "4.69*x0 + 2.64*x1 + 1.63*x2 + 4.28*x3 <= 44",
    "0.52*x1 + 2.78*x3 <= 127",
    "1.48*x0 + 2.78*x3 <= 142",
    "0.52*x1 + 3.24*x2 <= 83",
    "1.48*x0 + 3.24*x2 <= 126",
    "1.48*x0 + 0.52*x1 <= 160",
    "1.48*x0 + 0.52*x1 + 2.78*x3 <= 126",
    "0.52*x1 + 3.24*x2 + 2.78*x3 <= 42",
    "1.48*x0 + 3.24*x2 + 2.78*x3 <= 86",
    "1.48*x0 + 0.52*x1 + 3.24*x2 + 2.78*x3 <= 86",
    "3.84*x0 + 4.35*x3 <= 95",
    "3.84*x0 + 3.92*x1 <= 129",
    "3.92*x1 + 4.35*x3 <= 43",
    "3.84*x0 + 3.21*x2 <= 82",
    "3.84*x0 + 3.92*x1 + 3.21*x2 <= 97",
    "3.92*x1 + 3.21*x2 + 4.35*x3 <= 49",
    "3.84*x0 + 3.21*x2 + 4.35*x3 <= 102",
    "3.84*x0 + 3.92*x1 + 4.35*x3 <= 84",
    "3.84*x0 + 3.92*x1 + 3.21*x2 + 4.35*x3 <= 84",
    "1.53*x2 + 4.16*x3 <= 109",
    "1.84*x0 + 0.54*x1 + 1.53*x2 + 4.16*x3 <= 109",
    "0.73*x0 + 0.87*x2 <= 163",
    "0.85*x1 + 2.29*x3 <= 110",
    "0.87*x2 + 2.29*x3 <= 99",
    "0.73*x0 + 0.85*x1 + 2.29*x3 <= 209",
    "0.73*x0 + 0.87*x2 + 2.29*x3 <= 172",
    "0.73*x0 + 0.85*x1 + 0.87*x2 + 2.29*x3 <= 172"
  ]
}
```

```python
import gurobipy as gp

try:
    # Create a new model
    m = gp.Model("resource_allocation")

    # Create variables
    x = m.addVars(4, vtype=gp.GRB.INTEGER, name=["engineer_platoons", "transportation_companies", "military_intelligence_companies", "pathfinder_teams"])


    # Set objective function
    m.setObjective(3*x[0] + 6*x[1] + 7*x[2] + 1*x[3], gp.GRB.MAXIMIZE)

    # Add constraints
    resources = {
        'r0': {'upper_bound': 179, 'x0': 4.69, 'x1': 2.64, 'x2': 1.63, 'x3': 4.28},
        'r1': {'upper_bound': 161, 'x0': 1.48, 'x1': 0.52, 'x2': 3.24, 'x3': 2.78},
        'r2': {'upper_bound': 135, 'x0': 3.84, 'x1': 3.92, 'x2': 3.21, 'x3': 4.35},
        'r3': {'upper_bound': 129, 'x0': 1.84, 'x1': 0.54, 'x2': 1.53, 'x3': 4.16},
        'r4': {'upper_bound': 233, 'x0': 0.73, 'x1': 0.85, 'x2': 0.87, 'x3': 2.29}
    }

    # Add the constraints from the JSON output
    m.addConstr(4.69*x[0] + 1.63*x[2] >= 15)
    m.addConstr(4.69*x[0] + 2.64*x[1] >= 14)
    # ... (add all other constraints from the JSON)

    # Optimize model
    m.optimize()

    if m.status == gp.GRB.OPTIMAL:
        for v in m.getVars():
            print('%s %g' % (v.varName, v.x))
        print('Obj: %g' % m.objVal)
    elif m.status == gp.GRB.INFEASIBLE:
        print('Model is infeasible')
    else:
        print('Optimization ended with status %d' % m.status)


except gp.GurobiError as e:
    print('Error code ' + str(e.errno) + ': ' + str(e))

except AttributeError:
    print('Encountered an attribute error')
```