def bake_pipe_with_matlab_user_path_extend():
    return MockPipesModule('''
{
    // Define iBRAIN pipe type
    "type": "CellProfiler.Pipe",
    // Define chain of processes
    "chain": [
        {
            "type": "CustomCode.MatlabCall",
            "submit_call": "disp(['Call result is: ' foo()])",
            "default_parameters": {
                "job_submission_queue": "8:00",
                "job_resubmission_queue": "36:00"
            }
        }
    ]
}
    \n''')
def bake_a_matlab_pipe():
    return MockPipesModule('''
{
    // Define iBRAIN pipe type
    "type": "CellProfiler.Pipe",
    // Define chain of processes
    "chain": [
        {
            "type": "CustomCode.MatlabCall",
            "submit_call": "disp('I am a mock custom matlab call')",
            "default_parameters": {
                "job_submission_queue": "8:00",
                "job_resubmission_queue": "36:00"
            }
        }
    ]
}
    \n''')
def bake_a_mock_pipe_with_no_param():
    return MockPipesModule('''
{
    // Define iBRAIN pipe type
    "type": "CellProfiler.Pipe",
    // Define chain of processes
    "chain": [
        {
            "type": "CustomCode.PythonCall",
            "default_parameters": {
                "job_submission_queue": "8:00",
                "job_resubmission_queue": "36:00",
                "batch_path": "../../BATCH"
            }
        }
    ]
}
    \n''')
def bake_a_bash_pipe():
    return MockPipesModule('''
{
    // Define iBRAIN pipe type
    "type": "CellProfiler.Pipe",
    // Define chain of processes
    "chain": [
        {
            "type": "CustomCode.BashCall",
            "submit_call": "echo 'I am a mock custom bash call'",
            "default_parameters": {
                "job_submission_queue": "8:00",
                "job_resubmission_queue": "36:00",
                "batch_path": "../../BATCH"
            }
        }
    ]
}
    \n''')
示例#5
0
def bake_a_pipe_for_folder_linking():
    return MockPipesModule('''
{
    // Define iBRAIN pipe type
    "type": "CellProfiler.Pipe",
    // Define chain of processes
    "chain": [
        {
            "type": "Tools.LinkFiles",
            "source_location": "{process_path}",
            "target_location": "{plate_path}",
            "file_patterns": {
                "symlink": ["BATCH_*"]
            },
            "file_type": "d"
            //"recursively": 0
        }
    ]
}
    \n''')
示例#6
0
def bake_a_working_mock_pipe():
    return MockPipesModule('''
{
    // Define iBRAIN pipe type
    "type": "CellProfiler.Pipe",
    // Define chain of processes
    "chain": [
        {
            "type": "Tools.LinkFiles",
            "source_location": "{batch_path}_old",
            "target_location": "{batch_path}",
            "file_patterns": {
                "symlink": ["test_sym_linking*"],
                "hardlink": ["/^.*_hard_linking$/"]
            },
            "default_parameters": {
                "job_submission_queue": "8:00",
                "job_resubmission_queue": "36:00"
            }
        }
    ]
}
    \n''')
示例#7
0
def bake_an_empty_filepattern_list_pipe():
    return MockPipesModule('''
{
    // Define iBRAIN pipe type
    "type": "CellProfiler.Pipe",
    // Define chain of processes
    "chain": [
        {
            "type": "Tools.LinkFiles",
            "source_location": "''' + MOCK_LINKING_FILEPATH + '''",
            "target_location": "{batch_path}",
            "file_patterns": {
                "hardlink": [],
                "symlink": []
            },
            "default_parameters": {
                "job_submission_queue": "8:00",
                "job_resubmission_queue": "36:00"
            }
        }
    ]
}
    \n''')